Databases Reference
In-Depth Information
SQL azure Migration Wizard
the tools discussed so far in the chapter are provided by Microsoft. however, a standout third-party utility is
available, which was built specifically for migrating data to SQL azure. that utility is the SQL azure Migration
Wizard, and it deserves some well-earned attention.
the goal of the SQL azure Migration Wizard is to help you migrate your local SQL Server 2005/2008 databases
into SQL azure. this utility is wizard-driven, making it very easy to use. it walks you step by step through all that
is required, so migration is simple and nearly seamless.
You can find the SQL azure Migration Wizard on Codeplex at http://sqlazuremw.codeplex.com/ .
note that although this nifty utility migrates 2005, 2008, and 2012 databases, it requires a minimum of SQL
Server 2008 r2 to run.
SQL Azure Backup Strategies
Your data is in the cloud, but it really doesn't stop there. Much of the functionality that DBAs have at their fingertips
when dealing with local data stores doesn't exist in the cloud yet. The operative word in that sentence is yet .
Database Copy enables you to copy your database to make a new database on the same SQL Azure server.
Alternatively, you can copy to a different SQL Azure server in the same subregion or data center. This functionality is
much needed, but at the same time it has some shortcomings; some can be worked around, but others will require
future service updates.
Copying a Database
The Database Copy feature allows you to create a single copy of a source database. You do so by adding a new
argument to the CREATE DATABASE statement: AS COPY OF . As a refresher, the syntax for CREATE DATABASE is as
follows:
CREATE DATABASE MyDatabase (MAXSIZE= 10 GB, EDITION= 'Business')
To create a copy of a source database, the syntax now becomes
CREATE DATABASE MyDatabase AS COPY OF [ source_server_name ]. source_database_name ]
Thus, if you want to create a copy of your AWMini database, the syntax is
CREATE DATABASE AWMini2 AS COPY OF servername .AWMini
Figure 4-23 shows the execution of the previous statement. The interesting thing to note is the message in
the Messages window. When you execute the CREATE DATABASE statement with the AS COPY OF argument, you
immediately get the “Command(s) completed successfully” message. Does this mean the copy finished that quickly?
No. This message means the copy has started . You can also see in Figure 4-23 that the AWMini2 database is already
listed in the list of databases; however, that doesn't mean the database copy has completed.
 
Search WWH ::




Custom Search