I wanting to know how to run the 'Update-Database' command for a production database.
The 'Update-Database' database works fine from my local machine, but how do I get this to work for production data?
So, if I make a change to my application and then run the 'publish' through visual studio this works fine for the code side of things, but how do I run the 'Update-Database' command for the production data.
Hope this question makes sense...
Thanks,
See Using Entity Framework (code first) migrations in production so that your application automatically updates the database when the Entity Framework initializes.
Now if you're more comfortable having manual control over the migration, you could use the -Script argument to the Update-Database command on your developer machine to generate SQL scripts which you can then run against the production database.
http://msdn.microsoft.com/en-us/data/jj591621.aspx (see Getting A SQL Script section)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With