https://docs.microsoft.com/en-us/learn/modules/azure-sql-deploy-configure/
In this lab we will practice In this lab we will practice Deploying Azure SQL Database
You have two option to complete this lab
Login to Microsoft
Sign into you Microsoft Account
Click on activate sanbox.
Open a new tab in browser and open https://portal.azure.com
Sign in with Microsoft account you used in previous step.
If you get below message click on X to close it
Else go to next step
In the top search bar, enter Azure SQL and wait for results so you can review what appears.
There are a lot of items and categories here, but basically this menu gives you filters for what you can search on. Let's break them down:
Select Azure SQL under Marketplace. This step will bring you to the Azure SQL create experience.
In SQL databases, select Single database > Create.
On the Basics tab, enter the following information:
Parameter | Value |
---|---|
Subscription | Concierge subscription |
Resource group | |
Database name | AdventureWorks |
Server | Select Create new, fill out the Server details pane as follows, and select OK: |
Server name: Enter a unique name for the server (for example, aw-server0406). | |
Location: Use a region that's close to you. | |
Authentication method: Use SQL authentication. | |
Server admin login: cloudadmin | |
Password/Confirm Password: Use a complex password that meets strong password requirements. Note this password for later use. | |
Want to use SQL elastic pool? | No |
Compute + storage | Leave the default of General Purpose, Gen5, 2 vCores, 32 GB storage |
Backup storage redundancy | Leave the default of Geo-redundant backup storage |
Select Next: Networking.
For Connectivity method, select Public endpoint. Select Yes for both Allow Azure services and resources to access this server and Add current client IP address.
For Connection policy, select Default.
Select Next: Security.
When you deploy Azure SQL Database in the portal, you're prompted about whether you want to Enable Microsoft Defender for SQL in a free trial. Select Start free trial.
After the free trial, it's billed according to the Microsoft Defender for Cloud Standard Tier pricing. After you enable it, you get functionality related to identifying/mitigating potential database vulnerabilities and threat detection.
Leave remaining defaults and select Next: Additional settings.
On the Additional settings tab, for Azure SQL Database you have the option to select the AdventureWorksLT database as the sample in the Azure portal. For this exercise, for Use existing data, select Sample.
Select Review + create. Here, you can review your deployment selections and the Azure Marketplace terms. Review all the options to ensure that all of your selections match the exercise instructions, and then select Create to deploy the service.
You're redirected to a pane where you can monitor the status of your deployment. You can also go to your resource group and select Deployments to open this same pane. It gives you the various deployments, their status, and more information. This deployment typically takes less than five minutes to deploy.
When your deployment is complete, select Go to resource.
Review the Overview pane for the SQL database in the Azure portal and confirm that the status is Online.
Check instructions to download and install SQL Server Management Studio (SSMS) here
First, we need the logical server name. On the Overview pane for your database, locate the Server name information. This will be the fully qualified domain name (FQDN) of your logical server, for example, aw-server0406.database.windows.net. Hover your mouse at the end of the name and select Copy to clipboard.
Let's connect to your Azure SQL Database logical server. On your local device, open SSMS if it's not open already, and create a new connection. Select Connect > Database Engine.
For Server name, paste the name of your Azure SQL Database logical server.
Change the authentication to SQL Server Authentication. Then enter the corresponding server admin login and password (the one you provided during deployment in the previous exercise).
Select Remember password, and then select Connect.
Note
Depending on your local configuration (for example, VPN), your client IP address might differ from the IP address that the Azure portal used during deployment. If it does, you'll get a pop-up message that says "Your client IP address does not have access to the server. Sign in to an Azure account and create a new firewall rule to enable access." If you get this message, sign in with the account you're using for the sandbox, and add a firewall rule for your client IP address. You can complete all of these steps by using the pop-up wizard in SSMS.
Expanding the databases and system databases should result in a view similar to the following.
Spend a few minutes exploring the differences, at first glance, between the Azure SQL Database logical server and SQL Server. You won't deploy a managed instance as part of this exercise, but the following image shows how a managed instance would appear in SSMS.
Summary
In this exercise, you saw how to deploy and connect to Azure SQL Database.
Clean up
The sandbox automatically cleans up your resources when you’re finished with this module.
When you’re working in your own subscription, it’s a good idea at the end of a project to identify whether you still need the resources you created. Resources left running can cost you money.
You can delete resources individually or delete the resource group to delete the entire set of resources.
Summary
In this exercise, you saw how to deploy and connect to Azure SQL Database.
Clean up
The sandbox automatically cleans up your resources when you’re finished with this module.
When you’re working in your own subscription, it’s a good idea at the end of a project to identify whether you still need the resources you created. Resources left running can cost you money.
You can delete resources individually or delete the resource group to delete the entire set of resources.