This article show you how to connect to Windows Azure SQL Database using SQL Server Import and Export Wizard. Once you understand how to connect to SQL Database, you can migrate data between SQL Database and other data sources/destinations.
For more information on using the wizard, see Importing and Exporting Data by Using the SQL Server Import and Export Wizard .
SQL Server Import and Export Wizard is capable of copying schema and data, but not other database objects like indexes, constraints and stored procedures. Because SQL Database only supports tables with a clustered index, migrating both schema and data at the same time will fail. The wizard is better used for migrating data only. For migrating schema and other SQL Database data migration options, see Overview of Options for Migrating Data and Schema to Windows Azure SQL Database.
When you migrating data from SQL Server to SQL Database, it is also important to note that SQL Database does not support all SQL Server data types and features. This can complicate the data migration process. For more information, see Guidelines and Limitations (Windows Azure SQL Database) and Comparing SQL Server with Windows Azure SQL Database.
You must complete the following steps:
The following procedures show you a custom solution for migrating both schema and data from SQL Server to SQL Database. As stated in the beginning of the article, the wizard is better used for migrating data only. The main goal of these procedures is to show you how to connect to SQL Database from the wizard.
To migrate schema from SQL Server to SQL Database
For more information on Encrypt and TrustServerCertifiate, see Security Guidelines and Limitations (Windows Azure SQL Database).
- Copying to [TableName] (Error) Messages Error 0xc020844b: Data Flow Task 1: An exception has occurred during data insertion, the message returned from the provider is: Tables without a clustered index are not supported in this version of SQL Server. Please create a clustered index and try again. (SQL Server Import and Export Wizard)
The error message indicates clustered index is required for SQL Database tables.
Note: Do not close the Wizard. You will come back to the wizard after you create clustered index for the table.
To create clustered index for the SQL Database table
create clustered index idxAddressID on person.address(addressid)
After you execute a statement, click the Messsage button to make sure the command is completed successfully.
To migrate data from SQL Server to SQL Database
Richard Mueller edited Revision 14. Comment: Replaced RGB values with color names in HTML to restore colors
Richard Mueller edited Revision 13. Comment: Added tags
Ed Price - MSFT edited Revision 11. Comment: Removing "(en-US)" from the title. Sorry. That community-driven practice came as a surprise to us, and we had to take time to get the Wiki Community Council to decide on it. Thanks!
Samuel Lester - MSFT edited Revision 10. Comment: Fixing a couple typos
patmas57 edited Revision 9. Comment: Branding updates
Jewel Lambert edited Revision 7. Comment: Corrected spelling typo
Ed Price - MSFT edited Revision 4. Comment: TOC
Jonathan Gao edited Revision 2. Comment: minor editing
Jonathan Gao edited Revision 1. Comment: fix some anchor links
Jonathan Gao edited Original. Comment: add anchors
Ed Price - MSFT edited Revision 8. Comment: Removed "In this article" since there's already a TOC.