How to back up a database in cloud SQL Azure to a local SQL Server

Source: Internet
Author: User
Tags data structures management studio sql server management sql server management studio

SQL Azure provides a range of data replication and synchronization mechanisms. For example, a local SQL Server database can be published on SQL Azure, and SQL Azure's database can be packaged and downloaded to a local SQL Server server, and you can also back up the database through the Data Sync service. and dynamic Data synchronization.

Data-tier applications

The data-tier application (Data-tier application, DAC) encapsulates all the database and instance objects used by an application, such as tables, indexes, views, stored procedures, and even users.

With this logical encapsulation, the developer can set up and modify the database directly, and then give the encapsulated database definition to the database administrator for deployment on any DAC-enabled database.

The DAC avoids the complexity of maintaining database scripts and also weakens the interdependence between developers and database administrators.

The DAC also provides automated database updates that ensure data is not lost in the process of updating data structures.

DAC also supports versioning, so developers and database administrators can manage different DAC versions like the source code version.

In the DAC operation process is often to surging ah two file types, one is. Bacpac, one is. Dacpac

-Bacpac:. Bacpac file contains the structure and data in a database. The database structure information is the same as the information in the. dacpac file, and the data is stored in JSON format.

Logically,. Bacpac is the equivalent of a database backup, and its primary role is in database porting.

- . Dacpac: . Dacpac file contains a structure in a database, whose primary role is to deploy the database structure to different environments and to update the database structure.

First we need to install SQL Server 2012 locally and install SQL Server Management Studio.

In this chapter I will explain how to import a database from SQL Azure in the cloud into a local SQL Server database.

1. Prepare first, we use SQL Server Management Studio to create a SQL Azure in the cloud, named leidb. Create several tables at the same time. The following figure:

2. Create a storage account, named leizhangstorage (you can choose whether the need for offsite redundancy according to your own needs), and create container named dbbackin storage, Set container permissions to private.

3. Log in to Windows Azure Management Portal and select the SQL Azure we created in step 1, click Export, as shown below:

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.