What Will I Learn?
- You will learn how to move or migrate SQL Server database to Azure SQL database.
- DACPAC Deployment
- BACPAC Deployment
Requirements
- Computer system
- Microsoft Azure free account
- Microsoft SQL Server Management Studio 2014 Express Version
Get Microsoft Azure free account here
Get Microsoft SQL Server Management Studio Express Version here
Difficulty
- Intermediate
Tutorial Contents
- Migrate existing SQL Server database to SQL Azure
- DACPAC Deployment
- BACPAC Deployment
DACPAC Deployment
We first need to connect to the database.I am connecting to my local SQL Express instance.
Expand databases.Find our database called AzureDac and navigate the table.This database contains a few records.
We will need to do first azure sign up .Then we need to create a new SQL azure database the our destination for the migration.
We are creating a database which name is test and include to resource group.The server need to configure settings like server name admin login and password.
We need to enter our azure connection information and click connect .
We now have a new SQL Azure database that we'll use as our destination
First option generate scrpits task.Click next here.We can choose the database objects we want to generate in our case .Choose the entire database and all objects selected.Click next.
Clicking on advanced specify that target SQL Azure engine.Find the script for the database engine type option and select SQL Azure database.And type of script is set to data and schema only.We want to save script file and next.And close the wizard.
We can deploy the script our destination SQL Azure database. Click our SQK Azure database in SQL Server Management studio and select new query and open our script file and execeute the script our SQL Azure databaseWe have the table and objects.
BACPAC Deployment
This is the another way for the migration.In our local SQL server find our database and go to from Tasks to the Deploy Database to Microsoft Azure SQL Database option.
The wizards appears than click Next.
After than from Deployment Settings we are connecting to the Azure database and click Next.
Finally when we check our query editor in Azure SQL database we will see our changes.
Summary
As you can see above how to migrating SQL Server database to SQL Azure with two ways.
Posted on Utopian.io - Rewarding Open Source Contributors