forked from Azure/azure-cli
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request Azure#6 from wu5bocheng/data-model-for-portal-sql
[Add] Add command group `microsoft.sql/servers` and `microsoft.sql/servers/databases`
- Loading branch information
Showing
3 changed files
with
528 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,227 @@ | ||
{ | ||
"resourceType": "Databases", | ||
"apiVersion": "2021-11-01", | ||
"learnMore": { | ||
"url": "https://docs.microsoft.com/cli/azure/sql/db" | ||
}, | ||
"commands": [ | ||
{ | ||
"name": "az sql db list", | ||
"description": "List databases on a server or elastic pool.", | ||
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases", | ||
"confirmation": false, | ||
"help": { | ||
"learnMore": { | ||
"url": "https://docs.microsoft.com/cli/azure/sql/db#az-sql-db-list" | ||
}, | ||
"parameterSets": [ | ||
{ | ||
"parameters": [ | ||
"[--elastic-pool]", | ||
"[--ids]", | ||
"[--resource-group]", | ||
"[--server]", | ||
"[--subscription]" | ||
] | ||
} | ||
] | ||
}, | ||
"examples": [ | ||
{ | ||
"description": "List databases on a server or elastic pool.", | ||
"parameters": [ | ||
{ | ||
"name": "--subscription", | ||
"value": "[path.subscriptionId]" | ||
}, | ||
{ | ||
"name": "--resource-group", | ||
"value": "[path.resourceGroupName]" | ||
}, | ||
{ | ||
"name": "--server", | ||
"value": "[path.serverName]" | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "az sql db show", | ||
"description": "Get the details for a database.", | ||
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}", | ||
"confirmation": false, | ||
"help": { | ||
"learnMore": { | ||
"url": "https://docs.microsoft.com/cli/azure/sql/db#az-sql-db-show" | ||
}, | ||
"parameterSets": [ | ||
{ | ||
"parameters": [ | ||
"[--ids]", | ||
"[--name]", | ||
"[--resource-group]", | ||
"[--server]", | ||
"[--subscription]" | ||
] | ||
} | ||
] | ||
}, | ||
"examples": [ | ||
{ | ||
"description": "Get the details for a database.", | ||
"parameters": [ | ||
{ | ||
"name": "--subscription", | ||
"value": "[path.subscriptionId]" | ||
}, | ||
{ | ||
"name": "--name", | ||
"value": "[path.databaseName]" | ||
}, | ||
{ | ||
"name": "--resource-group", | ||
"value": "[path.resourceGroupName]" | ||
}, | ||
{ | ||
"name": "--server", | ||
"value": "[path.serverName]" | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "az sql db delete", | ||
"description": "Delete a database.", | ||
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}", | ||
"confirmation": true, | ||
"help": { | ||
"learnMore": { | ||
"url": "https://docs.microsoft.com/cli/azure/sql/db#az-sql-db-delete" | ||
}, | ||
"parameterSets": [ | ||
{ | ||
"parameters": [ | ||
"[--ids]", | ||
"[--name]", | ||
"[--no-wait]", | ||
"[--resource-group]", | ||
"[--server]", | ||
"[--subscription]", | ||
"[--yes]" | ||
] | ||
} | ||
] | ||
}, | ||
"examples": [ | ||
{ | ||
"description": "Delete a database.", | ||
"parameters": [ | ||
{ | ||
"name": "--subscription", | ||
"value": "[path.subscriptionId]" | ||
}, | ||
{ | ||
"name": "--name", | ||
"value": "[path.databaseName]" | ||
}, | ||
{ | ||
"name": "--resource-group", | ||
"value": "[path.resourceGroupName]" | ||
}, | ||
{ | ||
"name": "--server", | ||
"value": "[path.serverName]" | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "az sql dw list", | ||
"description": "List data warehouses for a server.", | ||
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases", | ||
"confirmation": false, | ||
"help": { | ||
"learnMore": { | ||
"url": "https://docs.microsoft.com/cli/azure/sql/dw#az-sql-dw-list" | ||
}, | ||
"parameterSets": [ | ||
{ | ||
"parameters": [ | ||
"[--ids]", | ||
"[--resource-group]", | ||
"[--server]", | ||
"[--subscription]" | ||
] | ||
} | ||
] | ||
}, | ||
"examples": [ | ||
{ | ||
"description": "List data warehouses for a server.", | ||
"parameters": [ | ||
{ | ||
"name": "--subscription", | ||
"value": "[path.subscriptionId]" | ||
}, | ||
{ | ||
"name": "--resource-group", | ||
"value": "[path.resourceGroupName]" | ||
}, | ||
{ | ||
"name": "--server", | ||
"value": "[path.serverName]" | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "az sql dw show", | ||
"description": "Get the details for a data warehouse.", | ||
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}", | ||
"confirmation": false, | ||
"help": { | ||
"learnMore": { | ||
"url": "https://docs.microsoft.com/cli/azure/sql/dw#az-sql-dw-show" | ||
}, | ||
"parameterSets": [ | ||
{ | ||
"parameters": [ | ||
"[--ids]", | ||
"[--name]", | ||
"[--resource-group]", | ||
"[--server]", | ||
"[--subscription]" | ||
] | ||
} | ||
] | ||
}, | ||
"examples": [ | ||
{ | ||
"description": "Get the details for a data warehouse.", | ||
"parameters": [ | ||
{ | ||
"name": "--subscription", | ||
"value": "[path.subscriptionId]" | ||
}, | ||
{ | ||
"name": "--name", | ||
"value": "[path.databaseName]" | ||
}, | ||
{ | ||
"name": "--resource-group", | ||
"value": "[path.resourceGroupName]" | ||
}, | ||
{ | ||
"name": "--server", | ||
"value": "[path.serverName]" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
{ | ||
"resourceType": "ElasticPools", | ||
"apiVersion": "2021-11-01", | ||
"learnMore": { | ||
"url": "https://docs.microsoft.com/cli/azure/sql/elastic-pool" | ||
}, | ||
"commands": [ | ||
{ | ||
"name": "az sql elastic-pool list", | ||
"description": "Gets all elastic pools in a server.", | ||
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/elasticPools", | ||
"confirmation": false, | ||
"help": { | ||
"learnMore": { | ||
"url": "https://docs.microsoft.com/cli/azure/sql/elastic-pool#az-sql-elastic-pool-list" | ||
}, | ||
"parameterSets": [ | ||
{ | ||
"parameters": [ | ||
"[--ids]", | ||
"[--resource-group]", | ||
"[--server]", | ||
"[--skip]", | ||
"[--subscription]" | ||
] | ||
} | ||
] | ||
}, | ||
"examples": [ | ||
{ | ||
"description": "List all elastic pools in a server.", | ||
"parameters": [ | ||
{ | ||
"name": "--subscription", | ||
"value": "[path.subscriptionId]" | ||
}, | ||
{ | ||
"name": "--resource-group", | ||
"value": "[path.resourceGroupName]" | ||
}, | ||
{ | ||
"name": "--server", | ||
"value": "[path.serverName]" | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "az sql elastic-pool show", | ||
"description": "Gets an elastic pool.", | ||
"path": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/elasticPools/{elasticPoolName}", | ||
"confirmation": false, | ||
"help": { | ||
"learnMore": { | ||
"url": "https://docs.microsoft.com/cli/azure/sql/elastic-pool#az-sql-elastic-pool-show" | ||
}, | ||
"parameterSets": [ | ||
{ | ||
"parameters": [ | ||
"[--ids]", | ||
"[--name]", | ||
"[--resource-group]", | ||
"[--server]", | ||
"[--subscription]" | ||
] | ||
} | ||
] | ||
}, | ||
"examples": [ | ||
{ | ||
"description": "Get the details for a specific elastic pool.", | ||
"parameters": [ | ||
{ | ||
"name": "--subscription", | ||
"value": "[path.subscriptionId]" | ||
}, | ||
{ | ||
"name": "--name", | ||
"value": "[path.elasticPoolName]" | ||
}, | ||
{ | ||
"name": "--resource-group", | ||
"value": "[path.resourceGroupName]" | ||
}, | ||
{ | ||
"name": "--server", | ||
"value": "[path.serverName]" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
] | ||
} |
Oops, something went wrong.