Monday, December 21, 2020

How to create Azure SQL database

 Azure SQL is built upon the familiar SQL Server engine, so you can migrate applications with ease and continue to use the tools, languages, and resources you're familiar with. Your skills and experience transfer to the cloud, so you can do even more with what you already have. If you want to learn, how Azure SQL server work and its architecture. Please read my previous blog How AzureSQL works?  

Azure SQL Database is a relational database-as-a-service (DBaaS) hosted in Azure that falls into the industry category of Platform-as-a-Service (PaaS). There are two type of Azure SQL databases which we can use in our application.

1.       Azure SQL Database: Support modern cloud applications on an intelligent, managed database service, that includes serverless compute. It gives us two type of pricing model DTU and vCore. With the DTU model you pay one fixed price for your compute (or IO/memory), as well as your data storage and back up retention. With the vCore model you have separate charges for your compute (what type of node or compute power you're using) and a separate charge for your storage.

DTU: Fixed price for your compute and storage (or IO/Memory)

vCore: Compute charges + Your storage charges 

       Azure SQL Database offers the following deployment options

a.       Single Database: Used in modern application (SaaS, Microservice)

b.       Elastic Pool: Group of single databases

2.       Azure SQL Managed Instance: Modernize your existing SQL Server applications at scale with an intelligent fully managed instance as a service, with almost 100% feature parity with the SQL Server database engine. Best for most migrations to the cloud. It supports SQL Agent, database email and not supported SSRS

You can see in below diagram, each service offering can be characterized by the level of administration you have over the infrastructure, and by the degree of cost efficiency.

Create Azure SQL

Need follow steps to create Azure SQL with help of azure portal.

1.       Go to azure portal

2.       Once we login in portal then need to choose Azure SQL which type of deployment you want based on your requirement. I am going to create Single Database.


3.       Once database is selected then we need to click on Create button. It will open the form which need to fill based on your requirement. In this case I am choosing Basic computation configuration for this Azure SQL.

Once it will be created it will look like as below

4.       Once all the information filled then need to click on Networking button. Here we can set firewall rules and private endpoints for this database. We are not setting anything just leaving as default.

5.       Just click on Additional Settings button it will give us 2 options for SQL database.

a.       Database Source: User can restore database backup and add sample data in database.

b.       Database collation: Collation specifies how data is sorted and compared in a database.

I am taking all default options

6.       Once you make the changes based on your requirement click on Tags button to add any tag for billing purpose or resource identification in Azure. You can add like this DEV, UAT or LIVE environment tag for Azure resources. I am not adding any tag here.

7.       Click on Review+ Create button. It will check and validate all the entry you have entered for this database. If everything looks good Create button will enabled, then you just click on Create button it will create Azure database for you.

8.       Once database created. We can connect it from SSMS and it will display like as below in azure

Connect Azure database from SQL Server Management Studio (SSMS)

We can connect Azure database from SSMS. First, we need to add our local machine public IP address (Machine IP address where SSMS installed) in SQL database firewall in Azure portal

Now need to open SSMS application click on Connect label below Object Explorer

You need to put your Azure SQL server name, login details and click on Connect button and It will connect with Azure database

Hope it will help you to create SQL database in Azure. Next blog I will show you how to do assessment of your existing database and will migrate that database in Azure.  

Keep learning, keep sharing. Cheers


  1. This comment has been removed by the author.

  2. This information is very interesting. I liked your blog because the content was really impressive. Thank you for giving much information. Azure Data Migration Services


  3. Thanks for this wonderful blog, Keep sharing your thoughts like this...
    Azure Training in Chennai
    Microsoft Azure Online Training