The only way I could figure how to do it was create the schema on the localDB with code first and then manually change the database string to Azure and then run the code on Azure.. But that only gives me the schema and not the data..
Is there a better way like ? bacpac? Create a script instead? Or some other concept I am missing ?
1
Generating a script for just data from SQL Server Management Studio should work fine, but for a large amount of data you may have to save the script into a file and run it from the command line. This method will not allow you to synchronize changes made after the initial migration.
There are some excellent professional tools for dealing with this problem. I use Redgate’s SQL Data Compare to synchronise data from a local database to SQL Azure, which can either generate a script of the differences or update the target database itself.
1