Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Dec 22, 2012 06:07 PM by XIII
Dec 22, 2012 03:16 PM|LINK
I'm planning a new site and I think i'm going to use MVC and EF 5. Now I have a question about EF and code first. Lets say I build a simple guestbook with code first and publish it to the web. People writes in my guestbook, but after two weeks I like to
store the visitors ip in my database. Then I add the ip to my class and so on, but how does this work with code first? Will everything that is in my databes get lost? If it gets lost, is there a way to do this without the data getting lost? If so, can you
point me to a tutorial?
I have search the web but I cant find a good answer.
I'm using VS 2012, .NET 4.5 and EF 5
Dec 22, 2012 06:07 PM|LINK
since EF code first 4.3 you have the ability to make use of database migrations:
It's also featured in this presentation by Scott Guthrie: