How To Use Query Editor For Azure SQL Database In Azure Portal

Introduction

This article demonstrates how to use Query Editor for Azure SQL Database operation in Azure portal.

Prerequisites

Recommendation

Please click here to go through my previous article about “Creating an Azure SQL Database and Connecting through SQL Server Management Studio”.

Azure Portal is providing Query editor for the database operation, which is very good for us. We don’t need any software installation in our computer we can access and perform the task in online.

First of all, login to the Azure portal. Click here to go to Azure login page.

Azure

After signing into the Azure portal, click on the SQL databases from the left panel of the website, as shown in the below image.

Azure

We will get the created database. Click on the created database “employee”.

Azure

Now, click on “Tools” as in the below image.

Azure

Click on the “Query editor (preview)” menu.

Azure

Click on “Login”.

Azure

Enter the login credentials and click on “OK” button, as shown in below image.

Azure

Now, write the SQL query in the Query Editor.

Here, we are going to write SQL query for creating the table named as Designation and run it.

  1. CREATE TABLE Designation (Id int, Name varchar(250), Role varchar(500));  

Azure

Writing some more SQL Queries for inserting the records into the just created Designation table.

  1. INSERT INTO Designation VALUES (1, 'a''x');  
  2. INSERT INTO Designation VALUES (2, 'b''y');  
  3. INSERT INTO Designation VALUES (3, 'c''z');  

Azure

Now, we are going to retrieve all the records using SELECT query. We can also filter the records using filter textbox.

  1. SELECT * FROM Designation

Azure

Summary

In this article, we have learned how to access and perform database operations on existing database using Query editor in Azure portal.