Events
Mar 31, 11 PM - Apr 2, 11 PM
The biggest SQL, Fabric and Power BI learning event. March 31 – April 2. Use code FABINSIDER to save $400.
Register todayThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Applies to:
Azure SQL Database
Azure Synapse Analytics
Returns the edition (service tier), service objective (pricing tier), and elastic pool name, if any, for an Azure SQL database or a dedicated SQL pool in Azure Synapse Analytics.
master
database in an Azure SQL Database server, returns information on all databases.master
database. This applies to both dedicated SQL pools in Azure Synapse workspaces and dedicated SQL pools (formerly SQL DW).Column Name | Data type | Description |
---|---|---|
database_id |
int | The ID of the database, unique within the logical server. Joinable with sys.databases on the database_id column, but with not other system views where the database_id column is present. For details, see DB_ID. |
edition |
sysname | The service tier for the database or data warehouse: Basic, Standard, Premium or Data Warehouse. |
service_objective |
sysname | The pricing tier of the database. If the database is in an elastic pool, returns ElasticPool. On the Basic tier, returns Basic. Single database in a standard service tier returns one of the following: S0, S1, S2, S3, S4, S6, S7, S9 or S12. Single database in a premium tier returns of the following: P1, P2, P4, P6, P11 or P15. Azure Synapse Analytics returns DW100 through DW30000c. For details, see single databases, elastic pools, data warehouses |
elastic_pool_name |
sysname | The name of the elastic pool that the database belongs to. Returns NULL if the database is a single database or a dedicated SQL pool. |
Requires dbManager permission on the master
database. At the database level, the user must be the creator or owner.
To change the service settings, see ALTER DATABASE (Azure SQL Database) and ALTER DATABASE (Azure Synapse Analytics).
This catalog view is not supported in serverless SQL pools in Azure Synapse Analytics.
For information on pricing, see SQL Database options and performance: SQL Database Pricing and Azure Synapse Analytics Pricing.
This example can be run on the master
database or on Azure SQL Database user databases. The query returns the name, service, and performance tier information of the database(s).
SELECT d.name,
slo.*
FROM sys.databases d
JOIN sys.database_service_objectives slo
ON d.database_id = slo.database_id;
Events
Mar 31, 11 PM - Apr 2, 11 PM
The biggest SQL, Fabric and Power BI learning event. March 31 – April 2. Use code FABINSIDER to save $400.
Register todayTraining
Module
Scale multiple Azure SQL Databases with SQL elastic pools - Training
Learn how to create SQL elastic pools and how to use them to manage performance and cost for a collection of SQL databases.
Certification
Microsoft Certified: Azure Database Administrator Associate - Certifications
Administer an SQL Server database infrastructure for cloud, on-premises and hybrid relational databases using the Microsoft PaaS relational database offerings.