How to restore my Local database to Windows Azure Database?
AzureAzure Sql-DatabaseAzure StorageAzure Problem Overview
I have uploaded my application to Windows Azure Now I want to store My Local database to Windows Azure Database.
Please Suggest me how do I create table and backup the table there?
Azure Solutions
Solution 1 - Azure
There are couple of ways to do that:
- The most reliable (that I usually use) is using the SQL Azure Migration Wizard
- Then you have the "Generate Scripts" option in your SSMS (SQL Server Management Studio 2008 R2 or later). The generate Scripts option does have a feature to make SQL Azure compliant script. It can also script data. But I suggest using method one if you want to migrate data, too. SQL Azure Migration Wizard uses BCP tool, which dumps the data into binary files, while SSMS just generates inline INSERT Statements
- SSIS (SQL Server Integration Services) - you can create a Data Transfer task, but I would use it very rare for small DBs.
- Export/Import data tier application (using DACPAC package) - this will migrate your schema and can migrate your data as well.
UPDATE 2017-10-24
Azure SQL Database now supports transactional replication from your on-premises SQL Server. You can configure your Azure SQL Database as subscriber and your SQL Server on-premise as publisher. You can read more about database migration options and strategies here: https://docs.microsoft.com/en-us/azure/sql-database/sql-database-cloud-migrate
Update 2017-12-23
SQL Azure Migration Wizard has been replaced by Data Migration Assistant: https://docs.microsoft.com/en-us/azure/sql-database/sql-database-cloud-migrate
Solution 2 - Azure
If you already have a database on local machine then you can migrate it directly on Azure using SQL Management Studio. Follow these steps:
- Right click on the database name in SSMS
- Follow the wizard that appears then
Solution 3 - Azure
There are a few ways in which to achieve this functionality.
Solution 4 - Azure
I'm assuming you're referring to SQL Azure? If so, you'll probably want to use the SQL Azure Migration Wizard @ http://sqlazuremw.codeplex.com/
Solution 5 - Azure
SQL Server 2012 Management Studio and SQL Azure Tools also now has this option I believe.
In SSMS if you right click on the Databases root, there is an option "Import Data-tier Application...", which allows you to restore a BACPAC (you can also right click on a database, and select "Export Data-tier Application..." to export an existing database to a BACPAC).
SQL Server Data Tools enables Visual Studio 2010 with a Data Compare option, which can also be used to move data between two database instances (which would be suited to smaller data patches).