Databases - Create Or Update
Creates a new database or updates an existing database.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}?api-version=2021-11-01
URI Parameters
Name | In | Required | Type | Description |
---|---|---|---|---|
database
|
path | True |
string |
The name of the database. |
resource
|
path | True |
string |
The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal. |
server
|
path | True |
string |
The name of the server. |
subscription
|
path | True |
string |
The subscription ID that identifies an Azure subscription. |
api-version
|
query | True |
string |
The API version to use for the request. |
Request Body
Name | Required | Type | Description |
---|---|---|---|
location | True |
string |
Resource location. |
identity |
The Azure Active Directory identity of the database. |
||
properties.autoPauseDelay |
integer |
Time in minutes after which database is automatically paused. A value of -1 means that automatic pause is disabled |
|
properties.catalogCollation |
Collation of the metadata catalog. |
||
properties.collation |
string |
The collation of the database. |
|
properties.createMode |
Specifies the mode of database creation. Default: regular database creation. Copy: creates a database as a copy of an existing database. sourceDatabaseId must be specified as the resource ID of the source database. Secondary: creates a database as a secondary replica of an existing database. sourceDatabaseId must be specified as the resource ID of the existing primary database. PointInTimeRestore: Creates a database by restoring a point in time backup of an existing database. sourceDatabaseId must be specified as the resource ID of the existing database, and restorePointInTime must be specified. Recovery: Creates a database by restoring a geo-replicated backup. sourceDatabaseId must be specified as the recoverable database resource ID to restore. Restore: Creates a database by restoring a backup of a deleted database. sourceDatabaseId must be specified. If sourceDatabaseId is the database's original resource ID, then sourceDatabaseDeletionDate must be specified. Otherwise sourceDatabaseId must be the restorable dropped database resource ID and sourceDatabaseDeletionDate is ignored. restorePointInTime may also be specified to restore from an earlier point in time. RestoreLongTermRetentionBackup: Creates a database by restoring from a long term retention vault. recoveryServicesRecoveryPointResourceId must be specified as the recovery point resource ID. Copy, Secondary, and RestoreLongTermRetentionBackup are not supported for DataWarehouse edition. |
||
properties.elasticPoolId |
string |
The resource identifier of the elastic pool containing this database. |
|
properties.federatedClientId |
string |
The Client id used for cross tenant per database CMK scenario |
|
properties.highAvailabilityReplicaCount |
integer |
The number of secondary replicas associated with the database that are used to provide high availability. Not applicable to a Hyperscale database within an elastic pool. |
|
properties.isLedgerOn |
boolean |
Whether or not this database is a ledger database, which means all tables in the database are ledger tables. Note: the value of this property cannot be changed after the database has been created. |
|
properties.licenseType |
The license type to apply for this database. |
||
properties.longTermRetentionBackupResourceId |
string |
The resource identifier of the long term retention backup associated with create operation of this database. |
|
properties.maintenanceConfigurationId |
string |
Maintenance configuration id assigned to the database. This configuration defines the period when the maintenance updates will occur. |
|
properties.maxSizeBytes |
integer |
The max size of the database expressed in bytes. |
|
properties.minCapacity |
number |
Minimal capacity that database will always have allocated, if not paused |
|
properties.readScale |
The state of read-only routing. If enabled, connections that have application intent set to readonly in their connection string may be routed to a readonly secondary replica in the same region. Not applicable to a Hyperscale database within an elastic pool. |
||
properties.recoverableDatabaseId |
string |
The resource identifier of the recoverable database associated with create operation of this database. |
|
properties.recoveryServicesRecoveryPointId |
string |
The resource identifier of the recovery point associated with create operation of this database. |
|
properties.requestedBackupStorageRedundancy |
The storage account type to be used to store backups for this database. |
||
properties.restorableDroppedDatabaseId |
string |
The resource identifier of the restorable dropped database associated with create operation of this database. |
|
properties.restorePointInTime |
string |
Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database. |
|
properties.sampleName |
The name of the sample schema to apply when creating this database. |
||
properties.secondaryType |
The secondary type of the database if it is a secondary. Valid values are Geo and Named. |
||
properties.sourceDatabaseDeletionDate |
string |
Specifies the time that the database was deleted. |
|
properties.sourceDatabaseId |
string |
The resource identifier of the source database associated with create operation of this database. |
|
properties.sourceResourceId |
string |
The resource identifier of the source associated with the create operation of this database. This property is only supported for DataWarehouse edition and allows to restore across subscriptions. When sourceResourceId is specified, sourceDatabaseId, recoverableDatabaseId, restorableDroppedDatabaseId and sourceDatabaseDeletionDate must not be specified and CreateMode must be PointInTimeRestore, Restore or Recover. When createMode is PointInTimeRestore, sourceResourceId must be the resource ID of the existing database or existing sql pool, and restorePointInTime must be specified. When createMode is Restore, sourceResourceId must be the resource ID of restorable dropped database or restorable dropped sql pool. When createMode is Recover, sourceResourceId must be the resource ID of recoverable database or recoverable sql pool. When source subscription belongs to a different tenant than target subscription, “x-ms-authorization-auxiliary” header must contain authentication token for the source tenant. For more details about “x-ms-authorization-auxiliary” header see https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/authenticate-multi-tenant |
|
properties.zoneRedundant |
boolean |
Whether or not this database is zone redundant, which means the replicas of this database will be spread across multiple availability zones. |
|
sku |
The database SKU. The list of SKUs may vary by region and support offer. To determine the SKUs (including the SKU name, tier/edition, family, and capacity) that are available to your subscription in an Azure region, use the
|
||
tags |
object |
Resource tags. |
Responses
Name | Type | Description |
---|---|---|
200 OK |
Successfully updated the database. |
|
201 Created |
Successfully created the database. |
|
202 Accepted |
Creating or updating the database is in progress. |
|
Other Status Codes |
*** Error Responses: ***
|
Examples
Creates a data warehouse database as a cross-subscription restore from a backup of a dropped database.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw?api-version=2021-11-01
{
"location": "southeastasia",
"properties": {
"createMode": "Restore",
"sourceResourceId": "/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/srcsvr/restorableDroppedDatabases/srcdw,131403269876900000"
}
}
Sample response
{
"sku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"kind": "v12.0,user,datawarehouse,gen2",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 263882790666240,
"status": "Online",
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentServiceObjectiveName": "DW1000c",
"requestedServiceObjectiveName": "DW1000c",
"defaultSecondaryLocation": "eastus",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"currentSku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"currentBackupStorageRedundancy": "Geo"
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"name": "testdw",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"kind": "v12.0,user,datawarehouse,gen2",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 263882790666240,
"status": "Online",
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentServiceObjectiveName": "DW1000c",
"requestedServiceObjectiveName": "DW1000c",
"defaultSecondaryLocation": "eastus",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"currentSku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"currentBackupStorageRedundancy": "Geo"
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"name": "testdw",
"type": "Microsoft.Sql/servers/databases"
}
Creates a data warehouse database as a cross-subscription restore from a geo-backup.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-WestUS/providers/Microsoft.Sql/servers/testsvr/databases/testdw?api-version=2021-11-01
{
"location": "westus",
"properties": {
"createMode": "Recovery",
"sourceResourceId": "/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-SQL-EastUS/providers/Microsoft.Sql/servers/srcsvr/recoverabledatabases/srcdw"
}
}
Sample response
{
"sku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"kind": "v12.0,user,datawarehouse,gen2",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 263882790666240,
"status": "Online",
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentServiceObjectiveName": "DW1000c",
"requestedServiceObjectiveName": "DW1000c",
"defaultSecondaryLocation": "eastus",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"currentSku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"currentBackupStorageRedundancy": "Geo"
},
"location": "westus",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-WestUS/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"name": "testdw",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"kind": "v12.0,user,datawarehouse,gen2",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 263882790666240,
"status": "Online",
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentServiceObjectiveName": "DW1000c",
"requestedServiceObjectiveName": "DW1000c",
"defaultSecondaryLocation": "eastus",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"currentSku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"currentBackupStorageRedundancy": "Geo"
},
"location": "westus",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-WestUS/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"name": "testdw",
"type": "Microsoft.Sql/servers/databases"
}
Creates a data warehouse database as a cross-subscription restore from a restore point of an existing database.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw?api-version=2021-11-01
{
"location": "southeastasia",
"properties": {
"createMode": "PointInTimeRestore",
"sourceResourceId": "/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/srcsvr/databases/srcdw",
"restorePointInTime": "2022-01-22T05:35:31.503Z"
}
}
Sample response
{
"sku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"kind": "v12.0,user,datawarehouse,gen2",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 263882790666240,
"status": "Online",
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentServiceObjectiveName": "DW1000c",
"requestedServiceObjectiveName": "DW1000c",
"defaultSecondaryLocation": "eastus",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"currentSku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"currentBackupStorageRedundancy": "Geo"
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"name": "testdw",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"kind": "v12.0,user,datawarehouse,gen2",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 263882790666240,
"status": "Online",
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentServiceObjectiveName": "DW1000c",
"requestedServiceObjectiveName": "DW1000c",
"defaultSecondaryLocation": "eastus",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"currentSku": {
"name": "DataWarehouse",
"tier": "DataWarehouse",
"capacity": 9000
},
"currentBackupStorageRedundancy": "Geo"
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"name": "testdw",
"type": "Microsoft.Sql/servers/databases"
}
Creates a database as a copy.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbcopy?api-version=2021-11-01
{
"location": "southeastasia",
"sku": {
"name": "S0",
"tier": "Standard"
},
"properties": {
"createMode": "Copy",
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb"
}
}
Sample response
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbcopy",
"name": "dbcopy",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbcopy",
"name": "dbcopy",
"type": "Microsoft.Sql/servers/databases"
}
Creates a database as an on-line secondary.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2021-11-01
{
"location": "southeastasia",
"sku": {
"name": "S0",
"tier": "Standard"
},
"properties": {
"createMode": "Secondary",
"secondaryType": "Geo",
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-NorthEurope/providers/Microsoft.Sql/servers/testsvr1/databases/testdb"
}
}
Sample response
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"secondaryType": "Geo",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"secondaryType": "Geo",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
Creates a database as named replica secondary.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2021-11-01
{
"location": "southeastasia",
"sku": {
"name": "HS_Gen4",
"tier": "Hyperscale",
"capacity": 2
},
"properties": {
"createMode": "Secondary",
"secondaryType": "Named",
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-NorthEurope/providers/Microsoft.Sql/servers/testsvr1/databases/primarydb"
}
}
Sample response
{
"sku": {
"name": "HS_Gen4",
"tier": "Hyperscale",
"family": "Gen4",
"capacity": 2
},
"kind": "v12.0,user,vcore,hyperscale",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": -1,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "HS_Gen4",
"tier": "Hyperscale",
"family": "Gen4",
"capacity": 2
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "HS_Gen4_2",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "HS_Gen4_2",
"highAvailabilityReplicaCount": 0,
"licenseType": "LicenseIncluded",
"secondaryType": "Named",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "HS_Gen4",
"tier": "Hyperscale",
"family": "Gen4",
"capacity": 2
},
"kind": "v12.0,user,vcore,hyperscale",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": -1,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "HS_Gen4",
"tier": "Hyperscale",
"family": "Gen4",
"capacity": 2
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "HS_Gen4_2",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "HS_Gen4_2",
"highAvailabilityReplicaCount": 0,
"licenseType": "LicenseIncluded",
"secondaryType": "Named",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
Creates a database from PointInTimeRestore.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbpitr?api-version=2021-11-01
{
"location": "southeastasia",
"properties": {
"createMode": "PointInTimeRestore",
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SoutheastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"restorePointInTime": "2020-10-22T05:35:31.503Z"
}
}
Sample response
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "2463ef48-53e2-4c26-9781-2d7138080bfd",
"creationDate": "2020-10-23T20:31:35.807Z",
"currentServiceObjectiveName": "S0",
"requestedServiceObjectiveName": "S0",
"defaultSecondaryLocation": "SoutheastAsia",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"isInfraEncryptionEnabled": false,
"zoneRedundant": false,
"earliestRestoreDate": "2020-10-23T20:47:37Z",
"readScale": "Disabled",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"currentBackupStorageRedundancy": "Geo",
"requestedBackupStorageRedundancy": "Geo",
"isLedgerOn": false
},
"location": "SoutheastAsia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SoutheastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbpitr",
"name": "dbpitr",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "2463ef48-53e2-4c26-9781-2d7138080bfd",
"creationDate": "2020-10-23T20:31:35.807Z",
"currentServiceObjectiveName": "S0",
"requestedServiceObjectiveName": "S0",
"defaultSecondaryLocation": "SoutheastAsia",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"isInfraEncryptionEnabled": false,
"zoneRedundant": false,
"earliestRestoreDate": "2020-10-23T20:47:37Z",
"readScale": "Disabled",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"currentBackupStorageRedundancy": "Geo",
"requestedBackupStorageRedundancy": "Geo",
"isLedgerOn": false
},
"location": "SoutheastAsia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SoutheastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbpitr",
"name": "dbpitr",
"type": "Microsoft.Sql/servers/databases"
}
Creates a database with default mode.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2021-11-01
{
"location": "southeastasia",
"sku": {
"name": "S0",
"tier": "Standard"
},
"properties": {
"createMode": "Default",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 1073741824
}
}
Sample response
{
"sku": {
"name": "S0",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 1073741824,
"status": "Online",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"isInfraEncryptionEnabled": false,
"zoneRedundant": false,
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"isLedgerOn": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "S0",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 1073741824,
"status": "Online",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"isInfraEncryptionEnabled": false,
"zoneRedundant": false,
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"isLedgerOn": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
Creates a database with ledger on.
Sample request
Sample response
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentServiceObjectiveName": "S0",
"currentBackupStorageRedundancy": "Geo",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"zoneRedundant": false,
"isLedgerOn": true
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Zone",
"currentServiceObjectiveName": "S0",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Zone",
"requestedServiceObjectiveName": "S0",
"zoneRedundant": false,
"isLedgerOn": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
Creates a database with minimum number of parameters.
Sample request
Sample response
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentServiceObjectiveName": "S0",
"currentBackupStorageRedundancy": "Geo",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
Creates a database with preferred maintenance window.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2021-11-01
{
"location": "southeastasia",
"sku": {
"name": "S2",
"tier": "Standard"
},
"properties": {
"createMode": "Default",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 1073741824,
"maintenanceConfigurationId": "/subscriptions/00000000-1111-2222-3333-444444444444/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_SouthEastAsia_1"
}
}
Sample response
{
"sku": {
"name": "S2",
"tier": "Standard"
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 1073741824,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentServiceObjectiveName": "S2",
"defaultSecondaryLocation": "North Europe",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"isInfraEncryptionEnabled": false,
"zoneRedundant": false,
"earliestRestoreDate": "2020-08-29T06:41:18.283Z",
"readScale": "Disabled",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 50
},
"currentBackupStorageRedundancy": "Geo",
"requestedBackupStorageRedundancy": "Geo",
"maintenanceConfigurationId": "/subscriptions/00000000-1111-2222-3333-444444444444/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_SouthEastAsia_1",
"isLedgerOn": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "S2",
"tier": "Standard"
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 1073741824,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentServiceObjectiveName": "S2",
"defaultSecondaryLocation": "North Europe",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"isInfraEncryptionEnabled": false,
"zoneRedundant": false,
"earliestRestoreDate": "2020-08-29T06:41:18.283Z",
"readScale": "Disabled",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 50
},
"currentBackupStorageRedundancy": "Geo",
"requestedBackupStorageRedundancy": "Geo",
"maintenanceConfigurationId": "/subscriptions/00000000-1111-2222-3333-444444444444/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_SouthEastAsia_1",
"isLedgerOn": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
Creates a database with specified backup storage redundancy.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2021-11-01
{
"location": "southeastasia",
"properties": {
"requestedBackupStorageRedundancy": "Zone"
}
}
Sample response
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Zone",
"currentServiceObjectiveName": "S0",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Zone",
"requestedServiceObjectiveName": "S0",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"maxSizeBytes": 268435456000,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"currentSku": {
"name": "Standard",
"tier": "Standard",
"capacity": 10
},
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Zone",
"currentServiceObjectiveName": "S0",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Zone",
"requestedServiceObjectiveName": "S0",
"zoneRedundant": false,
"isLedgerOn": false,
"isInfraEncryptionEnabled": false
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
Creates a VCore database by specifying service objective name.
Sample request
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2021-11-01
{
"location": "southeastasia",
"sku": {
"name": "BC",
"family": "Gen4",
"capacity": 2
}
}
Sample response
{
"sku": {
"name": "BC_Gen4",
"tier": "BusinessCritical",
"family": "Gen4",
"capacity": 2
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"maxSizeBytes": 1073741824,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentServiceObjectiveName": "BC_Gen4_2",
"defaultSecondaryLocation": "North Europe",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"licenseType": "LicenseIncluded",
"maxLogSizeBytes": 104857600,
"readScale": "Enabled",
"currentBackupStorageRedundancy": "Geo",
"requestedBackupStorageRedundancy": "Geo",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false,
"currentSku": {
"name": "BC_Gen4",
"tier": "BusinessCritical",
"capacity": 2
}
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "BC_Gen4",
"tier": "BusinessCritical",
"family": "Gen4",
"capacity": 2
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"maxSizeBytes": 1073741824,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentServiceObjectiveName": "BC_Gen4_2",
"defaultSecondaryLocation": "North Europe",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"licenseType": "LicenseIncluded",
"maxLogSizeBytes": 104857600,
"readScale": "Enabled",
"currentBackupStorageRedundancy": "Geo",
"requestedBackupStorageRedundancy": "Geo",
"isInfraEncryptionEnabled": false,
"zoneRedundant": false,
"isLedgerOn": false,
"currentSku": {
"name": "BC_Gen4",
"tier": "BusinessCritical",
"capacity": 2
}
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
Creates a VCore database by specifying sku name and capacity.
Sample request
Sample response
{
"sku": {
"name": "BC_Gen4",
"tier": "BusinessCritical",
"family": "Gen4",
"capacity": 2
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"maxSizeBytes": 1073741824,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentServiceObjectiveName": "BC_Gen4_2",
"defaultSecondaryLocation": "North Europe",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"licenseType": "LicenseIncluded",
"maxLogSizeBytes": 104857600,
"readScale": "Enabled",
"currentBackupStorageRedundancy": "Geo",
"requestedBackupStorageRedundancy": "Geo",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false,
"currentSku": {
"name": "BC_Gen4",
"tier": "BusinessCritical",
"capacity": 2
}
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
{
"sku": {
"name": "BC_Gen4",
"tier": "BusinessCritical",
"family": "Gen4",
"capacity": 2
},
"kind": "v12.0,user",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"maxSizeBytes": 1073741824,
"status": "Online",
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentServiceObjectiveName": "BC_Gen4_2",
"defaultSecondaryLocation": "North Europe",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"licenseType": "LicenseIncluded",
"maxLogSizeBytes": 104857600,
"readScale": "Enabled",
"currentBackupStorageRedundancy": "Geo",
"requestedBackupStorageRedundancy": "Geo",
"isLedgerOn": false,
"isInfraEncryptionEnabled": false,
"zoneRedundant": false,
"currentSku": {
"name": "BC_Gen4",
"tier": "BusinessCritical",
"capacity": 2
}
},
"location": "southeastasia",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"name": "testdb",
"type": "Microsoft.Sql/servers/databases"
}
Definitions
Name | Description |
---|---|
Backup |
The storage account type used to store backups for this database. |
Catalog |
Collation of the metadata catalog. |
Create |
Specifies the mode of database creation. Default: regular database creation. Copy: creates a database as a copy of an existing database. sourceDatabaseId must be specified as the resource ID of the source database. Secondary: creates a database as a secondary replica of an existing database. sourceDatabaseId must be specified as the resource ID of the existing primary database. PointInTimeRestore: Creates a database by restoring a point in time backup of an existing database. sourceDatabaseId must be specified as the resource ID of the existing database, and restorePointInTime must be specified. Recovery: Creates a database by restoring a geo-replicated backup. sourceDatabaseId must be specified as the recoverable database resource ID to restore. Restore: Creates a database by restoring a backup of a deleted database. sourceDatabaseId must be specified. If sourceDatabaseId is the database's original resource ID, then sourceDatabaseDeletionDate must be specified. Otherwise sourceDatabaseId must be the restorable dropped database resource ID and sourceDatabaseDeletionDate is ignored. restorePointInTime may also be specified to restore from an earlier point in time. RestoreLongTermRetentionBackup: Creates a database by restoring from a long term retention vault. recoveryServicesRecoveryPointResourceId must be specified as the recovery point resource ID. Copy, Secondary, and RestoreLongTermRetentionBackup are not supported for DataWarehouse edition. |
Database |
A database resource. |
Database |
Azure Active Directory identity configuration for a resource. |
Database |
The identity type |
Database |
The license type to apply for this database. |
Database |
The state of read-only routing. If enabled, connections that have application intent set to readonly in their connection string may be routed to a readonly secondary replica in the same region. Not applicable to a Hyperscale database within an elastic pool. |
Database |
The status of the database. |
Database |
Azure Active Directory identity configuration for a resource. |
Sample |
The name of the sample schema to apply when creating this database. |
Secondary |
The secondary type of the database if it is a secondary. Valid values are Geo and Named. |
Sku |
An ARM Resource SKU. |
BackupStorageRedundancy
The storage account type used to store backups for this database.
Name | Type | Description |
---|---|---|
Geo |
string |
|
GeoZone |
string |
|
Local |
string |
|
Zone |
string |
CatalogCollationType
Collation of the metadata catalog.
Name | Type | Description |
---|---|---|
DATABASE_DEFAULT |
string |
|
SQL_Latin1_General_CP1_CI_AS |
string |
CreateMode
Specifies the mode of database creation.
Default: regular database creation.
Copy: creates a database as a copy of an existing database. sourceDatabaseId must be specified as the resource ID of the source database.
Secondary: creates a database as a secondary replica of an existing database. sourceDatabaseId must be specified as the resource ID of the existing primary database.
PointInTimeRestore: Creates a database by restoring a point in time backup of an existing database. sourceDatabaseId must be specified as the resource ID of the existing database, and restorePointInTime must be specified.
Recovery: Creates a database by restoring a geo-replicated backup. sourceDatabaseId must be specified as the recoverable database resource ID to restore.
Restore: Creates a database by restoring a backup of a deleted database. sourceDatabaseId must be specified. If sourceDatabaseId is the database's original resource ID, then sourceDatabaseDeletionDate must be specified. Otherwise sourceDatabaseId must be the restorable dropped database resource ID and sourceDatabaseDeletionDate is ignored. restorePointInTime may also be specified to restore from an earlier point in time.
RestoreLongTermRetentionBackup: Creates a database by restoring from a long term retention vault. recoveryServicesRecoveryPointResourceId must be specified as the recovery point resource ID.
Copy, Secondary, and RestoreLongTermRetentionBackup are not supported for DataWarehouse edition.
Name | Type | Description |
---|---|---|
Copy |
string |
|
Default |
string |
|
OnlineSecondary |
string |
|
PointInTimeRestore |
string |
|
Recovery |
string |
|
Restore |
string |
|
RestoreExternalBackup |
string |
|
RestoreExternalBackupSecondary |
string |
|
RestoreLongTermRetentionBackup |
string |
|
Secondary |
string |
Database
A database resource.
Name | Type | Description |
---|---|---|
id |
string |
Resource ID. |
identity |
The Azure Active Directory identity of the database. |
|
kind |
string |
Kind of database. This is metadata used for the Azure portal experience. |
location |
string |
Resource location. |
managedBy |
string |
Resource that manages the database. |
name |
string |
Resource name. |
properties.autoPauseDelay |
integer |
Time in minutes after which database is automatically paused. A value of -1 means that automatic pause is disabled |
properties.catalogCollation |
Collation of the metadata catalog. |
|
properties.collation |
string |
The collation of the database. |
properties.createMode |
Specifies the mode of database creation. Default: regular database creation. Copy: creates a database as a copy of an existing database. sourceDatabaseId must be specified as the resource ID of the source database. Secondary: creates a database as a secondary replica of an existing database. sourceDatabaseId must be specified as the resource ID of the existing primary database. PointInTimeRestore: Creates a database by restoring a point in time backup of an existing database. sourceDatabaseId must be specified as the resource ID of the existing database, and restorePointInTime must be specified. Recovery: Creates a database by restoring a geo-replicated backup. sourceDatabaseId must be specified as the recoverable database resource ID to restore. Restore: Creates a database by restoring a backup of a deleted database. sourceDatabaseId must be specified. If sourceDatabaseId is the database's original resource ID, then sourceDatabaseDeletionDate must be specified. Otherwise sourceDatabaseId must be the restorable dropped database resource ID and sourceDatabaseDeletionDate is ignored. restorePointInTime may also be specified to restore from an earlier point in time. RestoreLongTermRetentionBackup: Creates a database by restoring from a long term retention vault. recoveryServicesRecoveryPointResourceId must be specified as the recovery point resource ID. Copy, Secondary, and RestoreLongTermRetentionBackup are not supported for DataWarehouse edition. |
|
properties.creationDate |
string |
The creation date of the database (ISO8601 format). |
properties.currentBackupStorageRedundancy |
The storage account type used to store backups for this database. |
|
properties.currentServiceObjectiveName |
string |
The current service level objective name of the database. |
properties.currentSku |
The name and tier of the SKU. |
|
properties.databaseId |
string |
The ID of the database. |
properties.defaultSecondaryLocation |
string |
The default secondary region for this database. |
properties.earliestRestoreDate |
string |
This records the earliest start date and time that restore is available for this database (ISO8601 format). |
properties.elasticPoolId |
string |
The resource identifier of the elastic pool containing this database. |
properties.failoverGroupId |
string |
Failover Group resource identifier that this database belongs to. |
properties.federatedClientId |
string |
The Client id used for cross tenant per database CMK scenario |
properties.highAvailabilityReplicaCount |
integer |
The number of secondary replicas associated with the database that are used to provide high availability. Not applicable to a Hyperscale database within an elastic pool. |
properties.isInfraEncryptionEnabled |
boolean |
Infra encryption is enabled for this database. |
properties.isLedgerOn |
boolean |
Whether or not this database is a ledger database, which means all tables in the database are ledger tables. Note: the value of this property cannot be changed after the database has been created. |
properties.licenseType |
The license type to apply for this database. |
|
properties.longTermRetentionBackupResourceId |
string |
The resource identifier of the long term retention backup associated with create operation of this database. |
properties.maintenanceConfigurationId |
string |
Maintenance configuration id assigned to the database. This configuration defines the period when the maintenance updates will occur. |
properties.maxLogSizeBytes |
integer |
The max log size for this database. |
properties.maxSizeBytes |
integer |
The max size of the database expressed in bytes. |
properties.minCapacity |
number |
Minimal capacity that database will always have allocated, if not paused |
properties.pausedDate |
string |
The date when database was paused by user configuration or action(ISO8601 format). Null if the database is ready. |
properties.readScale |
The state of read-only routing. If enabled, connections that have application intent set to readonly in their connection string may be routed to a readonly secondary replica in the same region. Not applicable to a Hyperscale database within an elastic pool. |
|
properties.recoverableDatabaseId |
string |
The resource identifier of the recoverable database associated with create operation of this database. |
properties.recoveryServicesRecoveryPointId |
string |
The resource identifier of the recovery point associated with create operation of this database. |
properties.requestedBackupStorageRedundancy |
The storage account type to be used to store backups for this database. |
|
properties.requestedServiceObjectiveName |
string |
The requested service level objective name of the database. |
properties.restorableDroppedDatabaseId |
string |
The resource identifier of the restorable dropped database associated with create operation of this database. |
properties.restorePointInTime |
string |
Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database. |
properties.resumedDate |
string |
The date when database was resumed by user action or database login (ISO8601 format). Null if the database is paused. |
properties.sampleName |
The name of the sample schema to apply when creating this database. |
|
properties.secondaryType |
The secondary type of the database if it is a secondary. Valid values are Geo and Named. |
|
properties.sourceDatabaseDeletionDate |
string |
Specifies the time that the database was deleted. |
properties.sourceDatabaseId |
string |
The resource identifier of the source database associated with create operation of this database. |
properties.sourceResourceId |
string |
The resource identifier of the source associated with the create operation of this database. This property is only supported for DataWarehouse edition and allows to restore across subscriptions. When sourceResourceId is specified, sourceDatabaseId, recoverableDatabaseId, restorableDroppedDatabaseId and sourceDatabaseDeletionDate must not be specified and CreateMode must be PointInTimeRestore, Restore or Recover. When createMode is PointInTimeRestore, sourceResourceId must be the resource ID of the existing database or existing sql pool, and restorePointInTime must be specified. When createMode is Restore, sourceResourceId must be the resource ID of restorable dropped database or restorable dropped sql pool. When createMode is Recover, sourceResourceId must be the resource ID of recoverable database or recoverable sql pool. When source subscription belongs to a different tenant than target subscription, “x-ms-authorization-auxiliary” header must contain authentication token for the source tenant. For more details about “x-ms-authorization-auxiliary” header see https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/authenticate-multi-tenant |
properties.status |
The status of the database. |
|
properties.zoneRedundant |
boolean |
Whether or not this database is zone redundant, which means the replicas of this database will be spread across multiple availability zones. |
sku |
The database SKU. The list of SKUs may vary by region and support offer. To determine the SKUs (including the SKU name, tier/edition, family, and capacity) that are available to your subscription in an Azure region, use the
|
|
tags |
object |
Resource tags. |
type |
string |
Resource type. |
DatabaseIdentity
Azure Active Directory identity configuration for a resource.
Name | Type | Description |
---|---|---|
tenantId |
string |
The Azure Active Directory tenant id. |
type |
The identity type |
|
userAssignedIdentities |
<string,
Database |
The resource ids of the user assigned identities to use |
DatabaseIdentityType
The identity type
Name | Type | Description |
---|---|---|
None |
string |
|
UserAssigned |
string |
DatabaseLicenseType
The license type to apply for this database. LicenseIncluded
if you need a license, or BasePrice
if you have a license and are eligible for the Azure Hybrid Benefit.
Name | Type | Description |
---|---|---|
BasePrice |
string |
|
LicenseIncluded |
string |
DatabaseReadScale
The state of read-only routing. If enabled, connections that have application intent set to readonly in their connection string may be routed to a readonly secondary replica in the same region. Not applicable to a Hyperscale database within an elastic pool.
Name | Type | Description |
---|---|---|
Disabled |
string |
|
Enabled |
string |
DatabaseStatus
The status of the database.
Name | Type | Description |
---|---|---|
AutoClosed |
string |
|
Copying |
string |
|
Creating |
string |
|
Disabled |
string |
|
EmergencyMode |
string |
|
Inaccessible |
string |
|
Offline |
string |
|
OfflineChangingDwPerformanceTiers |
string |
|
OfflineSecondary |
string |
|
Online |
string |
|
OnlineChangingDwPerformanceTiers |
string |
|
Paused |
string |
|
Pausing |
string |
|
Recovering |
string |
|
RecoveryPending |
string |
|
Restoring |
string |
|
Resuming |
string |
|
Scaling |
string |
|
Shutdown |
string |
|
Standby |
string |
|
Starting |
string |
|
Stopped |
string |
|
Stopping |
string |
|
Suspect |
string |
DatabaseUserIdentity
Azure Active Directory identity configuration for a resource.
Name | Type | Description |
---|---|---|
clientId |
string |
The Azure Active Directory client id. |
principalId |
string |
The Azure Active Directory principal id. |
SampleName
The name of the sample schema to apply when creating this database.
Name | Type | Description |
---|---|---|
AdventureWorksLT |
string |
|
WideWorldImportersFull |
string |
|
WideWorldImportersStd |
string |
SecondaryType
The secondary type of the database if it is a secondary. Valid values are Geo and Named.
Name | Type | Description |
---|---|---|
Geo |
string |
|
Named |
string |
Sku
An ARM Resource SKU.
Name | Type | Description |
---|---|---|
capacity |
integer |
Capacity of the particular SKU. |
family |
string |
If the service has different generations of hardware, for the same SKU, then that can be captured here. |
name |
string |
The name of the SKU, typically, a letter + Number code, e.g. P3. |
size |
string |
Size of the particular SKU |
tier |
string |
The tier or edition of the particular SKU, e.g. Basic, Premium. |