asp.net mvc - Changing the structure of my database / edmx model -


i using edmx editor create database visually, whenever change structure, , choose option "generate database model", current data in database wiped.

is @ possible change structure of database, , retain data?

how people work around problem?

thank you

here solutions:

  1. use code first or database first workflow, suggested in comment question. note: can use code first existing database.
  2. maintain data insert script should run after every "generate database model".
  3. make schema changes in database first, use "update model database" instead of "generate database model".

if using code first workflow possibility you, recommend going route.

hope helps.


Popular posts from this blog

php - How should I create my API for mobile applications (Needs Authentication) -

5 Reasons to Blog Anonymously (and 5 Reasons Not To)

Google AdWords and AdSense - A Dynamic Small Business Marketing Duo