I've got an existing database with just one table. This table's most important columns are username and password, and on my asp mvc project i have a model with complementary fields related to a specific user. I'm new to this technology, so here we go.
First question:
Is it the same to add a connection to a sqlserver from the server explorer (left side in visual studio) than adding the .mdf file to App_Data. I've seen both on some tutorials, it's just that only the former is working for me and it doesn't appends the <add .. /> line to my Web.config file, the latter method throws an 'access denied' box.
Can you make a table from a model?. It doesn't matter if it's empty, or you have to create from sql-studio. This is for my already-coded model, i want it to end up on the same database as the other table.
I want to map models to tables, if is there a straightforward way to do this with a hard-coded config line (i'm done with tutos that do it with the designer), i think is the more sane method to get this code-first-db-first done.
ASP MVC 3, Visual Studio 2010 Profesional, Sql Server 2008 r2 Express