c# - Update MVC database first to reflect db changes -


i'm new mvc , have update model.

i have sql server database connected project, today add new column. need update mvc code reflect change.

everything online tells me update .edmx , .tt files update model wizard since auto generated, cannot find wizard in vs 2012 @ stand still.

is right way should doing this? tips great...thanks

there couple options can do:

  1. if database empty or there isn't lot of data care about, can drop database , recreate it.
  2. manually add column in database (after property in model)
  3. there called code first migrations. allow update database. here tutorial can @ this: http://msdn.microsoft.com/en-us/data/jj591621.aspx

Comments

Popular posts from this blog

c# - How Configure Devart dotConnect for SQLite Code First? -

java - Copying object fields -

c++ - Clear the memory after returning a vector in a function -