Databases - Create Or Update
创建新数据库或更新现有数据库。
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}?api-version=2025-01-01
URI 参数
| 名称 | 在 | 必需 | 类型 | 说明 |
|---|---|---|---|---|
|
database
|
path | True |
string |
数据库的名称。 |
|
resource
|
path | True |
string minLength: 1maxLength: 90 |
资源组的名称。 此名称不区分大小写。 |
|
server
|
path | True |
string |
服务器的名称。 |
|
subscription
|
path | True |
string (uuid) |
目标订阅的 ID。 该值必须是 UUID。 |
|
api-version
|
query | True |
string minLength: 1 |
用于此操作的 API 版本。 |
请求正文
| 名称 | 必需 | 类型 | 说明 |
|---|---|---|---|
| location | True |
string |
资源所在的地理位置 |
| identity |
数据库的 Azure Active Directory 标识。 |
||
| properties.autoPauseDelay |
integer (int32) |
数据库自动暂停的时间(以分钟为单位)。 -1 值表示禁用自动暂停 |
|
| properties.availabilityZone |
指定数据库固定到的可用性区域。 |
||
| properties.catalogCollation |
元数据目录的排序规则。 |
||
| properties.collation |
string |
数据库的排序规则。 |
|
| properties.createMode |
指定数据库创建模式。 默认值:常规数据库创建。 复制:将数据库创建为现有数据库的副本。 sourceDatabaseId 必须指定为源数据库的资源 ID。 辅助数据库:将数据库创建为现有数据库的次要副本。 sourceDatabaseId 必须指定为现有主数据库的资源 ID。 PointInTimeRestore:通过还原现有数据库的时间点备份来创建数据库。 sourceDatabaseId 必须指定为现有数据库的资源 ID,并且必须指定 restorePointInTime。 恢复:通过还原异地复制的备份来创建数据库。 sourceDatabaseId 必须指定为可恢复的数据库资源 ID 才能还原。 还原:通过还原已删除数据库的备份来创建数据库。 必须指定 sourceDatabaseId。 如果 sourceDatabaseId 是数据库的原始资源 ID,则必须指定 sourceDatabaseDeletionDate。 否则,sourceDatabaseId 必须是可还原删除的数据库资源 ID,并且将忽略 sourceDatabaseDeletionDate。 还可以指定 restorePointInTime,以便从以前的时间点还原。 RestoreLongTermRetentionBackup:通过从长期保留保管库还原来创建数据库。 recoveryServicesRecoveryPointResourceId 必须指定为恢复点资源 ID。 DataWarehouse 版本不支持 Copy、Secondary 和 RestoreLongTermRetentionBackup。 |
||
| properties.elasticPoolId |
string (arm-id) |
包含此数据库的弹性池的资源标识符。 |
|
| properties.encryptionProtector |
string |
如果数据库配置了每个数据库客户管理的密钥,则数据库的 Azure 密钥保管库 URI。 |
|
| properties.encryptionProtectorAutoRotation |
boolean |
用于启用或禁用数据库加密保护程序 AKV 密钥自动轮换的标志。 |
|
| properties.federatedClientId |
string (uuid) |
用于每个数据库 CMK 方案的跨租户的客户端 ID |
|
| properties.freeLimitExhaustionBehavior |
指定免费数据库使用每月免费限制时的行为。 AutoPause:当剩余月份的可用限制用尽时,数据库将自动暂停。 BillForUsage:在耗尽免费限制后,数据库将继续联机,并且将收取任何超额费用。 |
||
| properties.highAvailabilityReplicaCount |
integer (int32) |
与用于提供高可用性的业务关键版、高级版或超大规模版数据库关联的次要副本数。 不适用于弹性池中的“超大规模”数据库。 |
|
| properties.isLedgerOn |
boolean |
此数据库是否为账本数据库,这意味着数据库中的所有表都是账本表。 注意:创建数据库后,无法更改此属性的值。 |
|
| properties.keys |
<string,
Database |
要使用的用户分配标识的资源 ID |
|
| properties.licenseType |
要申请此数据库的许可证类型。 如果需要许可证, |
||
| properties.longTermRetentionBackupResourceId |
string (arm-id) |
与此数据库的创建操作关联的长期保留备份的资源标识符。 |
|
| properties.maintenanceConfigurationId |
string |
分配给数据库的维护配置 ID。 此配置定义维护更新的发生时间。 |
|
| properties.manualCutover |
boolean |
在“更新数据库”操作到“超大规模”层期间,是否需要执行客户控制的手动直接转换。 仅当将数据库从业务关键/常规用途/高级/标准层缩放到“超大规模”层时,此属性才适用。 指定 manualCutover 时,缩放操作将等待用户输入触发“超大规模”数据库的直接转换。 若要触发直接转换,请在缩放操作处于等待状态时提供“performCutover”参数。 |
|
| properties.maxSizeBytes |
integer (int64) |
以字节表示的数据库的最大大小。 |
|
| properties.minCapacity |
number (double) |
数据库始终分配的最小容量(如果未暂停) |
|
| properties.performCutover |
boolean |
在缩放操作正在进行期间触发客户控制的手动直接转换。 此属性参数仅适用于随“manualCutover”参数一起启动的缩放操作。 仅当正在将数据库从业务关键/常规用途/高级/标准层缩放到“超大规模”层时,此属性才适用。 指定 performCutover 时,缩放操作将触发直接转换并执行超大规模数据库的角色更改。 |
|
| properties.preferredEnclaveType |
在数据库(即默认或 VBS enclave)上请求的 enclave 类型。 |
||
| properties.readScale |
只读路由的状态。 如果启用,将应用程序意向设置为只读的连接在其连接字符串中可能会路由到同一区域中的只读次要副本。 不适用于弹性池中的“超大规模”数据库。 |
||
| properties.recoverableDatabaseId |
string (arm-id) |
与此数据库的创建作关联的可恢复数据库的资源标识符。 |
|
| properties.recoveryServicesRecoveryPointId |
string (arm-id) |
与此数据库的创建操作关联的恢复点的资源标识符。 |
|
| properties.requestedBackupStorageRedundancy |
用于存储此数据库的备份的存储帐户类型。 |
||
| properties.restorableDroppedDatabaseId |
string (arm-id) |
与此数据库的创建操作关联的可还原已删除数据库的资源标识符。 |
|
| properties.restorePointInTime |
string (date-time) |
指定将还原以创建新数据库的源数据库的时间点(ISO8601格式)。 |
|
| properties.sampleName |
创建此数据库时要应用的示例架构的名称。 |
||
| properties.secondaryType |
数据库的辅助类型(如果是辅助数据库)。 有效值为 Geo、Named 和 Standby。 |
||
| properties.sourceDatabaseDeletionDate |
string (date-time) |
指定删除数据库的时间。 |
|
| properties.sourceDatabaseId |
string (arm-id) |
与此数据库的创建作关联的源数据库的资源标识符。 |
|
| properties.sourceResourceId |
string (arm-id) |
与此数据库的创建操作关联的源的资源标识符。 仅 DataWarehouse 版本支持此属性,并允许跨订阅还原。 指定 sourceResourceId 时,sourceDatabaseId、recoverableDatabaseId、restoreableDroppedDatabaseId 和 sourceDatabaseDeletionDate 不得指定,CreateMode 必须是 PointInTimeRestore、Restore 或 Recover。 createMode 为 PointInTimeRestore 时,sourceResourceId 必须是现有数据库或现有 sql 池的资源 ID,并且必须指定 restorePointInTime。 当 createMode 为 Restore 时,sourceResourceId 必须是可还原的已删除数据库或可还原的已删除 sql 池的资源 ID。 CreateMode 为 Recover 时,sourceResourceId 必须是可恢复数据库或可恢复 SQL 池的资源 ID。 当源订阅属于与目标订阅不同的租户时,“x-ms-authorization-auxiliary”标头必须包含源租户的身份验证令牌。 有关“x-ms-authorization-auxiliary”标头的更多详细信息,请参阅 https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/authenticate-multi-tenant |
|
| properties.useFreeLimit |
boolean |
数据库是否使用免费的每月限制。 在订阅中的一个数据库上允许。 |
|
| properties.zoneRedundant |
boolean |
此数据库是否为区域冗余,这意味着此数据库的副本将分布在多个可用性区域。 |
|
| sku |
数据库 SKU。 SKU 列表可能因区域和支持产品/服务而异。 若要确定 Azure 区域中订阅可用的 SKU(包括 SKU 名称、层/版本、系列和容量),请使用
|
||
| tags |
object |
资源标记。 |
响应
| 名称 | 类型 | 说明 |
|---|---|---|
| 200 OK |
资源“数据库”更新作成功 |
|
| 201 Created |
资源“数据库”创建作成功 标头 Azure-AsyncOperation: string |
|
| 202 Accepted |
已接受资源作。 标头
|
|
| Other Status Codes |
未预期的错误响应。 |
安全性
azure_auth
Azure Active Directory OAuth2 流程。
类型:
oauth2
流向:
implicit
授权 URL:
https://login.microsoftonline.com/common/oauth2/authorize
作用域
| 名称 | 说明 |
|---|---|
| user_impersonation | 冒充您的用户账户 |
示例
Creates a data warehouse database as a cross-subscription restore from a backup of a dropped database.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw?api-version=2025-01-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"
}
}
示例响应
{
"name": "testdw",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"kind": "v12.0,user,datawarehouse,gen2",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "DW1000c",
"currentSku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
},
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"defaultSecondaryLocation": "eastus",
"maxSizeBytes": 263882790666240,
"readScale": "Disabled",
"requestedServiceObjectiveName": "DW1000c",
"status": "Online"
},
"sku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
}
}
{
"name": "testdw",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"kind": "v12.0,user,datawarehouse,gen2",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "DW1000c",
"currentSku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
},
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"defaultSecondaryLocation": "eastus",
"maxSizeBytes": 263882790666240,
"readScale": "Disabled",
"requestedServiceObjectiveName": "DW1000c",
"status": "Online"
},
"sku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a data warehouse database as a cross-subscription restore from a geo-backup.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-WestUS/providers/Microsoft.Sql/servers/testsvr/databases/testdw?api-version=2025-01-01
{
"location": "westus",
"properties": {
"createMode": "Recovery",
"sourceResourceId": "/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-SQL-EastUS/providers/Microsoft.Sql/servers/srcsvr/recoverabledatabases/srcdw"
}
}
示例响应
{
"name": "testdw",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-WestUS/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"kind": "v12.0,user,datawarehouse,gen2",
"location": "westus",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "DW1000c",
"currentSku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
},
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"defaultSecondaryLocation": "eastus",
"maxSizeBytes": 263882790666240,
"readScale": "Disabled",
"requestedServiceObjectiveName": "DW1000c",
"status": "Online"
},
"sku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
}
}
{
"name": "testdw",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-WestUS/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"kind": "v12.0,user,datawarehouse,gen2",
"location": "westus",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "DW1000c",
"currentSku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
},
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"defaultSecondaryLocation": "eastus",
"maxSizeBytes": 263882790666240,
"readScale": "Disabled",
"requestedServiceObjectiveName": "DW1000c",
"status": "Online"
},
"sku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a data warehouse database as a cross-subscription restore from a restore point of an existing database.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"createMode": "PointInTimeRestore",
"restorePointInTime": "2022-01-22T05:35:31.503Z",
"sourceResourceId": "/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/srcsvr/databases/srcdw"
}
}
示例响应
{
"name": "testdw",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"kind": "v12.0,user,datawarehouse,gen2",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "DW1000c",
"currentSku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
},
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"defaultSecondaryLocation": "eastus",
"maxSizeBytes": 263882790666240,
"readScale": "Disabled",
"requestedServiceObjectiveName": "DW1000c",
"status": "Online"
},
"sku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
}
}
{
"name": "testdw",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdw",
"kind": "v12.0,user,datawarehouse,gen2",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2022-01-24T06:46:14.99Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "DW1000c",
"currentSku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
},
"databaseId": "188784c9-d602-4684-86cf-e67b6f03551a",
"defaultSecondaryLocation": "eastus",
"maxSizeBytes": 263882790666240,
"readScale": "Disabled",
"requestedServiceObjectiveName": "DW1000c",
"status": "Online"
},
"sku": {
"name": "DataWarehouse",
"capacity": 9000,
"tier": "DataWarehouse"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database as a copy.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbcopy?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"createMode": "Copy",
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb"
},
"sku": {
"name": "S0",
"tier": "Standard"
}
}
示例响应
{
"name": "dbcopy",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbcopy",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "dbcopy",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbcopy",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database as a standby secondary.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"createMode": "Secondary",
"secondaryType": "Standby",
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-NorthEurope/providers/Microsoft.Sql/servers/testsvr1/databases/testdb"
},
"sku": {
"name": "S0",
"tier": "Standard"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"secondaryType": "Standby",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"secondaryType": "Standby",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
Creates a database as an on-line secondary.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"createMode": "Secondary",
"secondaryType": "Geo",
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-NorthEurope/providers/Microsoft.Sql/servers/testsvr1/databases/testdb"
},
"sku": {
"name": "S0",
"tier": "Standard"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"secondaryType": "Geo",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"secondaryType": "Geo",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database as named replica secondary.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"createMode": "Secondary",
"secondaryType": "Named",
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-NorthEurope/providers/Microsoft.Sql/servers/testsvr1/databases/primarydb"
},
"sku": {
"name": "HS_Gen4",
"capacity": 2,
"tier": "Hyperscale"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user,vcore,hyperscale",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "HS_Gen4_2",
"currentSku": {
"name": "HS_Gen4",
"capacity": 2,
"family": "Gen4",
"tier": "Hyperscale"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"highAvailabilityReplicaCount": 0,
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"licenseType": "LicenseIncluded",
"maxSizeBytes": -1,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "HS_Gen4_2",
"secondaryType": "Named",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "HS_Gen4",
"capacity": 2,
"family": "Gen4",
"tier": "Hyperscale"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user,vcore,hyperscale",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "HS_Gen4_2",
"currentSku": {
"name": "HS_Gen4",
"capacity": 2,
"family": "Gen4",
"tier": "Hyperscale"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"highAvailabilityReplicaCount": 0,
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"licenseType": "LicenseIncluded",
"maxSizeBytes": -1,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "HS_Gen4_2",
"secondaryType": "Named",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "HS_Gen4",
"capacity": 2,
"family": "Gen4",
"tier": "Hyperscale"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database from PointInTimeRestore.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbpitr?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"createMode": "PointInTimeRestore",
"restorePointInTime": "2020-10-22T05:35:31.503Z",
"sourceDatabaseId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SoutheastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb"
}
}
示例响应
{
"name": "dbpitr",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SoutheastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbpitr",
"kind": "v12.0,user",
"location": "SoutheastAsia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2020-10-23T20:31:35.807Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "2463ef48-53e2-4c26-9781-2d7138080bfd",
"defaultSecondaryLocation": "SoutheastAsia",
"earliestRestoreDate": "2020-10-23T20:47:37Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "dbpitr",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SoutheastAsia/providers/Microsoft.Sql/servers/testsvr/databases/dbpitr",
"kind": "v12.0,user",
"location": "SoutheastAsia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2020-10-23T20:31:35.807Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "2463ef48-53e2-4c26-9781-2d7138080bfd",
"defaultSecondaryLocation": "SoutheastAsia",
"earliestRestoreDate": "2020-10-23T20:47:37Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database with availability zone specified.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"availabilityZone": "1",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"createMode": "Default",
"maxSizeBytes": 1073741824
},
"sku": {
"name": "S0",
"tier": "Standard"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"availabilityZone": "1",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S0",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"availabilityZone": "1",
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S0",
"capacity": 10,
"tier": "Standard"
}
}
Creates a database with database-level customer managed keys.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/00000000-1111-2222-3333-444444444444/resourcegroups/Default-SQL-SouthEastAsia/providers/Microsoft.ManagedIdentity/userAssignedIdentities/umi": {}
}
},
"location": "southeastasia",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"createMode": "Default",
"encryptionProtector": "https://your-key-vault-name.vault.azure.net/yourKey/yourKeyVersion",
"keys": {
"https://your-key-vault-name.vault.azure.net/yourKey/yourKeyVersion": {},
"https://your-key-vault-name.vault.azure.net/yourKey2/yourKey2Version": {}
},
"maxSizeBytes": 1073741824
},
"sku": {
"name": "S0",
"tier": "Standard"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S0",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S0",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database with database-level versionless customer managed keys.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/00000000-1111-2222-3333-444444444444/resourcegroups/Default-SQL-SouthEastAsia/providers/Microsoft.ManagedIdentity/userAssignedIdentities/umi": {}
}
},
"location": "southeastasia",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"createMode": "Default",
"encryptionProtector": "https://your-key-vault-name.vault.azure.net/yourKey",
"keys": {
"https://your-key-vault-name.vault.azure.net/yourKey": {},
"https://your-key-vault-name.vault.azure.net/yourKey2": {}
},
"maxSizeBytes": 1073741824
},
"sku": {
"name": "S0",
"tier": "Standard"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S0",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S0",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database with Default enclave type.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"preferredEnclaveType": "Default"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"maxSizeBytes": 268435456000,
"preferredEnclaveType": "Default",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Zone",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"maxSizeBytes": 268435456000,
"preferredEnclaveType": "Default",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Zone",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database with default mode.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"createMode": "Default",
"maxSizeBytes": 1073741824
},
"sku": {
"name": "S0",
"tier": "Standard"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S0",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S0",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database with encryption protector auto rotation.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/00000000-1111-2222-3333-444444444444/resourcegroups/Default-SQL-SouthEastAsia/providers/Microsoft.ManagedIdentity/userAssignedIdentities/umi": {}
}
},
"location": "southeastasia",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"createMode": "Default",
"encryptionProtector": "https://your-key-vault-name.vault.azure.net/yourKey/yourKeyVersion",
"encryptionProtectorAutoRotation": true,
"maxSizeBytes": 1073741824
},
"sku": {
"name": "S0",
"tier": "Standard"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"encryptionProtector": "https://your-key-vault-name.vault.azure.net/yourKey/yourKeyVersion",
"encryptionProtectorAutoRotation": true,
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S0",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S0",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database with ledger on.
示例请求
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isLedgerOn": true,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Zone",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Zone",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database with minimum number of parameters.
示例请求
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database with preferred maintenance window.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"collation": "SQL_Latin1_General_CP1_CI_AS",
"createMode": "Default",
"maintenanceConfigurationId": "/subscriptions/00000000-1111-2222-3333-444444444444/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_SouthEastAsia_1",
"maxSizeBytes": 1073741824
},
"sku": {
"name": "S2",
"tier": "Standard"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S2",
"currentSku": {
"name": "Standard",
"capacity": 50,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2020-08-29T06:41:18.283Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maintenanceConfigurationId": "/subscriptions/00000000-1111-2222-3333-444444444444/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_SouthEastAsia_1",
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S2",
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S2",
"currentSku": {
"name": "Standard",
"capacity": 50,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2020-08-29T06:41:18.283Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maintenanceConfigurationId": "/subscriptions/00000000-1111-2222-3333-444444444444/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_SouthEastAsia_1",
"maxSizeBytes": 1073741824,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "S2",
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database with specified backup storage redundancy.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"location": "southeastasia",
"properties": {
"requestedBackupStorageRedundancy": "Zone"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Zone",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Zone",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Zone",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"maxSizeBytes": 268435456000,
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Zone",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a database with VBS enclave type.
示例请求
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"maxSizeBytes": 268435456000,
"preferredEnclaveType": "VBS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Zone",
"currentServiceObjectiveName": "S0",
"currentSku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"maxSizeBytes": 268435456000,
"preferredEnclaveType": "VBS",
"readScale": "Disabled",
"requestedBackupStorageRedundancy": "Zone",
"requestedServiceObjectiveName": "S0",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "Standard",
"capacity": 10,
"tier": "Standard"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a VCore database by specifying service objective name.
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"location": "southeastasia",
"sku": {
"name": "BC",
"capacity": 2,
"family": "Gen4"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "BC_Gen4_2",
"currentSku": {
"name": "BC_Gen4",
"capacity": 2,
"tier": "BusinessCritical"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"licenseType": "LicenseIncluded",
"maxLogSizeBytes": 104857600,
"maxSizeBytes": 1073741824,
"readScale": "Enabled",
"requestedBackupStorageRedundancy": "Geo",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "BC_Gen4",
"capacity": 2,
"family": "Gen4",
"tier": "BusinessCritical"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "BC_Gen4_2",
"currentSku": {
"name": "BC_Gen4",
"capacity": 2,
"tier": "BusinessCritical"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"licenseType": "LicenseIncluded",
"maxLogSizeBytes": 104857600,
"maxSizeBytes": 1073741824,
"readScale": "Enabled",
"requestedBackupStorageRedundancy": "Geo",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "BC_Gen4",
"capacity": 2,
"family": "Gen4",
"tier": "BusinessCritical"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Creates a VCore database by specifying sku name and capacity.
示例请求
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "BC_Gen4_2",
"currentSku": {
"name": "BC_Gen4",
"capacity": 2,
"tier": "BusinessCritical"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"licenseType": "LicenseIncluded",
"maxLogSizeBytes": 104857600,
"maxSizeBytes": 1073741824,
"readScale": "Enabled",
"requestedBackupStorageRedundancy": "Geo",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "BC_Gen4",
"capacity": 2,
"family": "Gen4",
"tier": "BusinessCritical"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2017-06-07T04:41:33.937Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "BC_Gen4_2",
"currentSku": {
"name": "BC_Gen4",
"capacity": 2,
"tier": "BusinessCritical"
},
"databaseId": "6c764297-577b-470f-9af4-96d3d41e2ba3",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2017-06-07T04:51:33.937Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"licenseType": "LicenseIncluded",
"maxLogSizeBytes": 104857600,
"maxSizeBytes": 1073741824,
"readScale": "Enabled",
"requestedBackupStorageRedundancy": "Geo",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "BC_Gen4",
"capacity": 2,
"family": "Gen4",
"tier": "BusinessCritical"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Updates a database to Hyperscale SLO with manual cutover
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/00000000-1111-2222-3333-444444444444/resourcegroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/userAssignedIdentities/umi": {},
"/subscriptions/00000000-1111-2222-3333-444444444444/resourcegroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/userAssignedIdentities/umiToDelete": null
}
},
"location": "southeastasia",
"properties": {
"manualCutover": true
},
"sku": {
"name": "HS_Gen5_2",
"tier": "Hyperscale"
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user,vcore",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2022-12-08T12:41:23.953Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "GP_Gen5_2",
"currentSku": {
"name": "GP_Gen5",
"capacity": 2,
"family": "Gen5",
"tier": "GeneralPurpose"
},
"databaseId": "dad50ee1-9fbb-4fb9-bd2b-5786d175ce3c",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2022-12-08T12:42:00Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"licenseType": "LicenseIncluded",
"maintenanceConfigurationId": "/subscriptions/00000000-1111-2222-3333-444444444444/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_Default",
"maxLogSizeBytes": 193273528320,
"maxSizeBytes": 34359738368,
"readScale": "Enabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "HS_Gen5_2",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "HS_Gen5",
"capacity": 2,
"family": "Gen5",
"tier": "Hyperscale"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user,vcore",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2022-12-08T12:41:23.953Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "GP_Gen5_2",
"currentSku": {
"name": "GP_Gen5",
"capacity": 2,
"family": "Gen5",
"tier": "GeneralPurpose"
},
"databaseId": "dad50ee1-9fbb-4fb9-bd2b-5786d175ce3c",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2022-12-08T12:42:00Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"licenseType": "LicenseIncluded",
"maintenanceConfigurationId": "/subscriptions/00000000-1111-2222-3333-444444444444/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_Default",
"maxLogSizeBytes": 193273528320,
"maxSizeBytes": 34359738368,
"readScale": "Enabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "HS_Gen5_2",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "HS_Gen5",
"capacity": 2,
"family": "Gen5",
"tier": "Hyperscale"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
Updates a database to Hyperscale tier by triggering manual cutover during Migration workflow
示例请求
PUT https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb?api-version=2025-01-01
{
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/00000000-1111-2222-3333-444444444444/resourcegroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/userAssignedIdentities/umi": {},
"/subscriptions/00000000-1111-2222-3333-444444444444/resourcegroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/userAssignedIdentities/umiToDelete": null
}
},
"location": "southeastasia",
"properties": {
"performCutover": true
}
}
示例响应
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user,vcore",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2022-12-08T12:41:23.953Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "GP_Gen5_2",
"currentSku": {
"name": "GP_Gen5",
"capacity": 2,
"family": "Gen5",
"tier": "GeneralPurpose"
},
"databaseId": "dad50ee1-9fbb-4fb9-bd2b-5786d175ce3c",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2022-12-08T12:42:00Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"licenseType": "LicenseIncluded",
"maintenanceConfigurationId": "/subscriptions/00000000-1111-2222-3333-444444444444/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_Default",
"maxLogSizeBytes": 193273528320,
"maxSizeBytes": 34359738368,
"readScale": "Enabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "HS_Gen5_2",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "HS_Gen5",
"capacity": 2,
"family": "Gen5",
"tier": "Hyperscale"
}
}
{
"name": "testdb",
"type": "Microsoft.Sql/servers/databases",
"id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/servers/testsvr/databases/testdb",
"kind": "v12.0,user,vcore",
"location": "southeastasia",
"properties": {
"catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
"collation": "SQL_Latin1_General_CP1_CI_AS",
"creationDate": "2022-12-08T12:41:23.953Z",
"currentBackupStorageRedundancy": "Geo",
"currentServiceObjectiveName": "GP_Gen5_2",
"currentSku": {
"name": "GP_Gen5",
"capacity": 2,
"family": "Gen5",
"tier": "GeneralPurpose"
},
"databaseId": "dad50ee1-9fbb-4fb9-bd2b-5786d175ce3c",
"defaultSecondaryLocation": "North Europe",
"earliestRestoreDate": "2022-12-08T12:42:00Z",
"isInfraEncryptionEnabled": false,
"isLedgerOn": false,
"licenseType": "LicenseIncluded",
"maintenanceConfigurationId": "/subscriptions/00000000-1111-2222-3333-444444444444/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_Default",
"maxLogSizeBytes": 193273528320,
"maxSizeBytes": 34359738368,
"readScale": "Enabled",
"requestedBackupStorageRedundancy": "Geo",
"requestedServiceObjectiveName": "HS_Gen5_2",
"status": "Online",
"zoneRedundant": false
},
"sku": {
"name": "HS_Gen5",
"capacity": 2,
"family": "Gen5",
"tier": "Hyperscale"
}
}
Location: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-SouthEastAsia/providers/Microsoft.Sql/locations/southeastasia/databaseOperationResults/11111111-1111-1111-1111-111111111111
定义
| 名称 | 说明 |
|---|---|
|
Always |
在数据库(即默认或 VBS enclave)上请求的 enclave 类型。 |
|
Availability |
指定数据库固定到的可用性区域。 |
|
Backup |
用于存储此数据库的备份的存储帐户类型。 |
|
Catalog |
元数据目录的排序规则。 |
|
created |
创建该资源的身份类型。 |
|
Create |
指定数据库创建模式。 默认值:常规数据库创建。 复制:将数据库创建为现有数据库的副本。 sourceDatabaseId 必须指定为源数据库的资源 ID。 辅助数据库:将数据库创建为现有数据库的次要副本。 sourceDatabaseId 必须指定为现有主数据库的资源 ID。 PointInTimeRestore:通过还原现有数据库的时间点备份来创建数据库。 sourceDatabaseId 必须指定为现有数据库的资源 ID,并且必须指定 restorePointInTime。 恢复:通过还原异地复制的备份来创建数据库。 sourceDatabaseId 必须指定为可恢复的数据库资源 ID 才能还原。 还原:通过还原已删除数据库的备份来创建数据库。 必须指定 sourceDatabaseId。 如果 sourceDatabaseId 是数据库的原始资源 ID,则必须指定 sourceDatabaseDeletionDate。 否则,sourceDatabaseId 必须是可还原删除的数据库资源 ID,并且将忽略 sourceDatabaseDeletionDate。 还可以指定 restorePointInTime,以便从以前的时间点还原。 RestoreLongTermRetentionBackup:通过从长期保留保管库还原来创建数据库。 recoveryServicesRecoveryPointResourceId 必须指定为恢复点资源 ID。 DataWarehouse 版本不支持 Copy、Secondary 和 RestoreLongTermRetentionBackup。 |
| Database |
数据库资源。 |
|
Database |
资源的 Azure Active Directory 标识配置。 |
|
Database |
标识类型 |
|
Database |
用于静态加密的数据库级密钥。 |
|
Database |
数据库密钥类型。 仅支持的值是“AzureKeyVault”。 |
|
Database |
要申请此数据库的许可证类型。 如果需要许可证, |
|
Database |
只读路由的状态。 如果启用,将应用程序意向设置为只读的连接在其连接字符串中可能会路由到同一区域中的只读次要副本。 不适用于弹性池中的“超大规模”数据库。 |
|
Database |
数据库的状态。 |
|
Database |
资源的 Azure Active Directory 标识配置。 |
|
Error |
资源管理错误附加信息。 |
|
Error |
错误详细信息。 |
|
Error |
错误响应 |
|
Free |
指定免费数据库使用每月免费限制时的行为。 AutoPause:当剩余月份的可用限制用尽时,数据库将自动暂停。 BillForUsage:在耗尽免费限制后,数据库将继续联机,并且将收取任何超额费用。 |
|
Sample |
创建此数据库时要应用的示例架构的名称。 |
|
Secondary |
数据库的辅助类型(如果是辅助数据库)。 有效值为 Geo、Named 和 Standby。 |
| Sku |
表示 SKU 的资源模型定义 |
|
Sku |
如果服务具有多个层,但在 PUT 上不需要,则需要资源提供程序实现此字段。 |
|
system |
与创建和上次修改资源相关的元数据。 |
AlwaysEncryptedEnclaveType
在数据库(即默认或 VBS enclave)上请求的 enclave 类型。
| 值 | 说明 |
|---|---|
| Default |
默认 |
| VBS |
VBS |
AvailabilityZoneType
指定数据库固定到的可用性区域。
| 值 | 说明 |
|---|---|
| NoPreference |
无偏好 |
| 1 |
1 |
| 2 |
2 |
| 3 |
3 |
BackupStorageRedundancy
用于存储此数据库的备份的存储帐户类型。
| 值 | 说明 |
|---|---|
| Geo |
地理位置 |
| Local |
Local |
| Zone |
区域 |
| GeoZone |
GeoZone |
CatalogCollationType
元数据目录的排序规则。
| 值 | 说明 |
|---|---|
| DATABASE_DEFAULT |
DATABASE_DEFAULT |
| SQL_Latin1_General_CP1_CI_AS |
SQL_Latin1_General_CP1_CI_AS |
createdByType
创建该资源的身份类型。
| 值 | 说明 |
|---|---|
| User | |
| Application | |
| ManagedIdentity | |
| Key |
CreateMode
指定数据库创建模式。
默认值:常规数据库创建。
复制:将数据库创建为现有数据库的副本。 sourceDatabaseId 必须指定为源数据库的资源 ID。
辅助数据库:将数据库创建为现有数据库的次要副本。 sourceDatabaseId 必须指定为现有主数据库的资源 ID。
PointInTimeRestore:通过还原现有数据库的时间点备份来创建数据库。 sourceDatabaseId 必须指定为现有数据库的资源 ID,并且必须指定 restorePointInTime。
恢复:通过还原异地复制的备份来创建数据库。 sourceDatabaseId 必须指定为可恢复的数据库资源 ID 才能还原。
还原:通过还原已删除数据库的备份来创建数据库。 必须指定 sourceDatabaseId。 如果 sourceDatabaseId 是数据库的原始资源 ID,则必须指定 sourceDatabaseDeletionDate。 否则,sourceDatabaseId 必须是可还原删除的数据库资源 ID,并且将忽略 sourceDatabaseDeletionDate。 还可以指定 restorePointInTime,以便从以前的时间点还原。
RestoreLongTermRetentionBackup:通过从长期保留保管库还原来创建数据库。 recoveryServicesRecoveryPointResourceId 必须指定为恢复点资源 ID。
DataWarehouse 版本不支持 Copy、Secondary 和 RestoreLongTermRetentionBackup。
| 值 | 说明 |
|---|---|
| Default |
默认 |
| Copy |
复制 |
| Secondary |
次级 |
| PointInTimeRestore |
PointInTimeRestore |
| Restore |
Restore |
| Recovery |
恢复 |
| RestoreExternalBackup |
恢复外部备份 |
| RestoreExternalBackupSecondary |
恢复外部备份次级 |
| RestoreLongTermRetentionBackup |
恢复长期保留备份 |
| OnlineSecondary |
在线中学 |
Database
数据库资源。
| 名称 | 类型 | 说明 |
|---|---|---|
| id |
string (arm-id) |
该资源的完全限定资源 ID。 例如“/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}” |
| identity |
数据库的 Azure Active Directory 标识。 |
|
| kind |
string |
数据库类型。 这是用于 Azure 门户体验的元数据。 |
| location |
string |
资源所在的地理位置 |
| managedBy |
string |
管理数据库的资源。 |
| name |
string |
资源的名称 |
| properties.autoPauseDelay |
integer (int32) |
数据库自动暂停的时间(以分钟为单位)。 -1 值表示禁用自动暂停 |
| properties.availabilityZone |
指定数据库固定到的可用性区域。 |
|
| properties.catalogCollation |
元数据目录的排序规则。 |
|
| properties.collation |
string |
数据库的排序规则。 |
| properties.createMode |
指定数据库创建模式。 默认值:常规数据库创建。 复制:将数据库创建为现有数据库的副本。 sourceDatabaseId 必须指定为源数据库的资源 ID。 辅助数据库:将数据库创建为现有数据库的次要副本。 sourceDatabaseId 必须指定为现有主数据库的资源 ID。 PointInTimeRestore:通过还原现有数据库的时间点备份来创建数据库。 sourceDatabaseId 必须指定为现有数据库的资源 ID,并且必须指定 restorePointInTime。 恢复:通过还原异地复制的备份来创建数据库。 sourceDatabaseId 必须指定为可恢复的数据库资源 ID 才能还原。 还原:通过还原已删除数据库的备份来创建数据库。 必须指定 sourceDatabaseId。 如果 sourceDatabaseId 是数据库的原始资源 ID,则必须指定 sourceDatabaseDeletionDate。 否则,sourceDatabaseId 必须是可还原删除的数据库资源 ID,并且将忽略 sourceDatabaseDeletionDate。 还可以指定 restorePointInTime,以便从以前的时间点还原。 RestoreLongTermRetentionBackup:通过从长期保留保管库还原来创建数据库。 recoveryServicesRecoveryPointResourceId 必须指定为恢复点资源 ID。 DataWarehouse 版本不支持 Copy、Secondary 和 RestoreLongTermRetentionBackup。 |
|
| properties.creationDate |
string (date-time) |
数据库的创建日期(ISO8601格式)。 |
| properties.currentBackupStorageRedundancy |
用于存储此数据库的备份的存储帐户类型。 |
|
| properties.currentServiceObjectiveName |
string |
数据库的当前服务级别目标名称。 |
| properties.currentSku |
SKU 的名称和层。 |
|
| properties.databaseId |
string (uuid) |
数据库的 ID。 |
| properties.defaultSecondaryLocation |
string |
此数据库的默认次要区域。 |
| properties.earliestRestoreDate |
string (date-time) |
这会记录此数据库的最早开始日期和时间(ISO8601格式)。 |
| properties.elasticPoolId |
string (arm-id) |
包含此数据库的弹性池的资源标识符。 |
| properties.encryptionProtector |
string |
如果数据库配置了每个数据库客户管理的密钥,则数据库的 Azure 密钥保管库 URI。 |
| properties.encryptionProtectorAutoRotation |
boolean |
用于启用或禁用数据库加密保护程序 AKV 密钥自动轮换的标志。 |
| properties.failoverGroupId |
string |
此数据库所属的故障转移组资源标识符。 |
| properties.federatedClientId |
string (uuid) |
用于每个数据库 CMK 方案的跨租户的客户端 ID |
| properties.freeLimitExhaustionBehavior |
指定免费数据库使用每月免费限制时的行为。 AutoPause:当剩余月份的可用限制用尽时,数据库将自动暂停。 BillForUsage:在耗尽免费限制后,数据库将继续联机,并且将收取任何超额费用。 |
|
| properties.highAvailabilityReplicaCount |
integer (int32) |
与用于提供高可用性的业务关键版、高级版或超大规模版数据库关联的次要副本数。 不适用于弹性池中的“超大规模”数据库。 |
| properties.isInfraEncryptionEnabled |
boolean |
为此数据库启用了基础结构加密。 |
| properties.isLedgerOn |
boolean |
此数据库是否为账本数据库,这意味着数据库中的所有表都是账本表。 注意:创建数据库后,无法更改此属性的值。 |
| properties.keys |
<string,
Database |
要使用的用户分配标识的资源 ID |
| properties.licenseType |
要申请此数据库的许可证类型。 如果需要许可证, |
|
| properties.longTermRetentionBackupResourceId |
string (arm-id) |
与此数据库的创建操作关联的长期保留备份的资源标识符。 |
| properties.maintenanceConfigurationId |
string |
分配给数据库的维护配置 ID。 此配置定义维护更新的发生时间。 |
| properties.manualCutover |
boolean |
在“更新数据库”操作到“超大规模”层期间,是否需要执行客户控制的手动直接转换。 仅当将数据库从业务关键/常规用途/高级/标准层缩放到“超大规模”层时,此属性才适用。 指定 manualCutover 时,缩放操作将等待用户输入触发“超大规模”数据库的直接转换。 若要触发直接转换,请在缩放操作处于等待状态时提供“performCutover”参数。 |
| properties.maxLogSizeBytes |
integer (int64) |
此数据库的最大日志大小。 |
| properties.maxSizeBytes |
integer (int64) |
以字节表示的数据库的最大大小。 |
| properties.minCapacity |
number (double) |
数据库始终分配的最小容量(如果未暂停) |
| properties.pausedDate |
string (date-time) |
由用户配置或操作(ISO8601格式)暂停数据库的日期。 如果数据库准备就绪,则为 Null。 |
| properties.performCutover |
boolean |
在缩放操作正在进行期间触发客户控制的手动直接转换。 此属性参数仅适用于随“manualCutover”参数一起启动的缩放操作。 仅当正在将数据库从业务关键/常规用途/高级/标准层缩放到“超大规模”层时,此属性才适用。 指定 performCutover 时,缩放操作将触发直接转换并执行超大规模数据库的角色更改。 |
| properties.preferredEnclaveType |
在数据库(即默认或 VBS enclave)上请求的 enclave 类型。 |
|
| properties.readScale |
只读路由的状态。 如果启用,将应用程序意向设置为只读的连接在其连接字符串中可能会路由到同一区域中的只读次要副本。 不适用于弹性池中的“超大规模”数据库。 |
|
| properties.recoverableDatabaseId |
string (arm-id) |
与此数据库的创建作关联的可恢复数据库的资源标识符。 |
| properties.recoveryServicesRecoveryPointId |
string (arm-id) |
与此数据库的创建操作关联的恢复点的资源标识符。 |
| properties.requestedBackupStorageRedundancy |
用于存储此数据库的备份的存储帐户类型。 |
|
| properties.requestedServiceObjectiveName |
string |
请求的数据库服务级别目标名称。 |
| properties.restorableDroppedDatabaseId |
string (arm-id) |
与此数据库的创建操作关联的可还原已删除数据库的资源标识符。 |
| properties.restorePointInTime |
string (date-time) |
指定将还原以创建新数据库的源数据库的时间点(ISO8601格式)。 |
| properties.resumedDate |
string (date-time) |
用户操作或数据库登录恢复数据库的日期(ISO8601格式)。 如果暂停数据库,则为 Null。 |
| properties.sampleName |
创建此数据库时要应用的示例架构的名称。 |
|
| properties.secondaryType |
数据库的辅助类型(如果是辅助数据库)。 有效值为 Geo、Named 和 Standby。 |
|
| properties.sourceDatabaseDeletionDate |
string (date-time) |
指定删除数据库的时间。 |
| properties.sourceDatabaseId |
string (arm-id) |
与此数据库的创建作关联的源数据库的资源标识符。 |
| properties.sourceResourceId |
string (arm-id) |
与此数据库的创建操作关联的源的资源标识符。 仅 DataWarehouse 版本支持此属性,并允许跨订阅还原。 指定 sourceResourceId 时,sourceDatabaseId、recoverableDatabaseId、restoreableDroppedDatabaseId 和 sourceDatabaseDeletionDate 不得指定,CreateMode 必须是 PointInTimeRestore、Restore 或 Recover。 createMode 为 PointInTimeRestore 时,sourceResourceId 必须是现有数据库或现有 sql 池的资源 ID,并且必须指定 restorePointInTime。 当 createMode 为 Restore 时,sourceResourceId 必须是可还原的已删除数据库或可还原的已删除 sql 池的资源 ID。 CreateMode 为 Recover 时,sourceResourceId 必须是可恢复数据库或可恢复 SQL 池的资源 ID。 当源订阅属于与目标订阅不同的租户时,“x-ms-authorization-auxiliary”标头必须包含源租户的身份验证令牌。 有关“x-ms-authorization-auxiliary”标头的更多详细信息,请参阅 https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/authenticate-multi-tenant |
| properties.status |
数据库的状态。 |
|
| properties.useFreeLimit |
boolean |
数据库是否使用免费的每月限制。 在订阅中的一个数据库上允许。 |
| properties.zoneRedundant |
boolean |
此数据库是否为区域冗余,这意味着此数据库的副本将分布在多个可用性区域。 |
| sku |
数据库 SKU。 SKU 列表可能因区域和支持产品/服务而异。 若要确定 Azure 区域中订阅可用的 SKU(包括 SKU 名称、层/版本、系列和容量),请使用
|
|
| systemData |
包含 createdBy 和 modifiedBy 信息的 Azure 资源管理器元数据。 |
|
| tags |
object |
资源标记。 |
| type |
string |
资源类型。 例如“Microsoft.Compute/virtualMachines”或“Microsoft.Storage/storageAccounts” |
DatabaseIdentity
资源的 Azure Active Directory 标识配置。
| 名称 | 类型 | 说明 |
|---|---|---|
| tenantId |
string (uuid) |
Azure Active Directory 租户 ID。 |
| type |
标识类型 |
|
| userAssignedIdentities |
<string,
Database |
要使用的用户分配标识的资源 ID |
DatabaseIdentityType
标识类型
| 值 | 说明 |
|---|---|
| None |
None |
| UserAssigned |
UserAssigned |
DatabaseKey
用于静态加密的数据库级密钥。
| 名称 | 类型 | 说明 |
|---|---|---|
| creationDate |
string (date-time) |
数据库密钥创建日期。 |
| keyVersion |
string |
数据库密钥的版本。 |
| subregion |
string |
服务器密钥的子区域。 |
| thumbprint |
string |
数据库密钥的指纹。 |
| type |
数据库密钥类型。 仅支持的值是“AzureKeyVault”。 |
DatabaseKeyType
数据库密钥类型。 仅支持的值是“AzureKeyVault”。
| 值 | 说明 |
|---|---|
| AzureKeyVault |
AzureKeyVault |
DatabaseLicenseType
要申请此数据库的许可证类型。 如果需要许可证,LicenseIncluded,或者 BasePrice 拥有许可证并且有资格获得 Azure 混合权益。
| 值 | 说明 |
|---|---|
| LicenseIncluded |
包含许可 |
| BasePrice |
BasePrice |
DatabaseReadScale
只读路由的状态。 如果启用,将应用程序意向设置为只读的连接在其连接字符串中可能会路由到同一区域中的只读次要副本。 不适用于弹性池中的“超大规模”数据库。
| 值 | 说明 |
|---|---|
| Enabled |
已启用 |
| Disabled |
Disabled |
DatabaseStatus
数据库的状态。
| 值 | 说明 |
|---|---|
| Online |
在线 |
| Restoring |
恢复 |
| RecoveryPending |
恢复待处理 |
| Recovering |
恢复 |
| Suspect |
怀疑 |
| Offline |
离线 |
| Standby |
备用 |
| Shutdown |
关机 |
| EmergencyMode |
紧急模式 |
| AutoClosed |
自动关闭 |
| Copying |
复制 |
| Creating |
创建 |
| Inaccessible |
无法 |
| OfflineSecondary |
离线次要 |
| Pausing |
暂停 |
| Paused |
已暂停 |
| Resuming |
继续 |
| Scaling |
Scaling |
| OfflineChangingDwPerformanceTiers |
离线变更DW性能等级 |
| OnlineChangingDwPerformanceTiers |
在线变动DW性能层级 |
| Disabled |
Disabled |
| Stopping |
停止中 |
| Stopped |
已停止 |
| Starting |
正在启动 |
DatabaseUserIdentity
资源的 Azure Active Directory 标识配置。
| 名称 | 类型 | 说明 |
|---|---|---|
| clientId |
string (uuid) |
Azure Active Directory 客户端 ID。 |
| principalId |
string (uuid) |
Azure Active Directory 主体 ID。 |
ErrorAdditionalInfo
资源管理错误附加信息。
| 名称 | 类型 | 说明 |
|---|---|---|
| info |
object |
附加信息。 |
| type |
string |
附加信息类型。 |
ErrorDetail
错误详细信息。
| 名称 | 类型 | 说明 |
|---|---|---|
| additionalInfo |
错误附加信息。 |
|
| code |
string |
错误代码。 |
| details |
错误详细信息。 |
|
| message |
string |
错误消息。 |
| target |
string |
错误目标。 |
ErrorResponse
错误响应
| 名称 | 类型 | 说明 |
|---|---|---|
| error |
错误对象。 |
FreeLimitExhaustionBehavior
指定免费数据库使用每月免费限制时的行为。
AutoPause:当剩余月份的可用限制用尽时,数据库将自动暂停。
BillForUsage:在耗尽免费限制后,数据库将继续联机,并且将收取任何超额费用。
| 值 | 说明 |
|---|---|
| AutoPause |
自动暂停 |
| BillOverUsage |
账单过度使用 |
SampleName
创建此数据库时要应用的示例架构的名称。
| 值 | 说明 |
|---|---|
| AdventureWorksLT |
冒险工作LT |
| WideWorldImportersStd |
WideWorldImportersStd |
| WideWorldImportersFull |
WideWorldImportersFull |
SecondaryType
数据库的辅助类型(如果是辅助数据库)。 有效值为 Geo、Named 和 Standby。
| 值 | 说明 |
|---|---|
| Geo |
地理位置 |
| Named |
名为 |
| Standby |
备用 |
Sku
表示 SKU 的资源模型定义
| 名称 | 类型 | 说明 |
|---|---|---|
| capacity |
integer (int32) |
如果 SKU 支持横向扩展/缩减,则应包含容量整数。 如果资源无法横向扩展/缩小,则可能会省略此范围。 |
| family |
string |
如果服务具有不同代的硬件(对于同一 SKU,则可以在此处捕获)。 |
| name |
string |
SKU 的名称。 例如 P3。 它通常是字母+数字代码 |
| size |
string |
SKU 大小。 当名称字段是层和其他一些值的组合时,这将是独立的代码。 |
| tier |
如果服务具有多个层,但在 PUT 上不需要,则需要资源提供程序实现此字段。 |
SkuTier
如果服务具有多个层,但在 PUT 上不需要,则需要资源提供程序实现此字段。
| 值 | 说明 |
|---|---|
| Free | |
| Basic | |
| Standard | |
| Premium |
systemData
与创建和上次修改资源相关的元数据。
| 名称 | 类型 | 说明 |
|---|---|---|
| createdAt |
string (date-time) |
资源创建时间戳(UTC)。 |
| createdBy |
string |
创建该资源的身份。 |
| createdByType |
创建该资源的身份类型。 |
|
| lastModifiedAt |
string (date-time) |
上次修改的资源时间戳(UTC) |
| lastModifiedBy |
string |
上次修改资源的标识。 |
| lastModifiedByType |
上次修改资源的标识的类型。 |