az cosmosdb table

注意

此命令群組具有 Azure CLI 和至少一個擴充功能中定義的命令。 安裝每個擴充功能以受益於其擴充功能。 深入了解擴充功能。

管理 Azure Cosmos DB 帳戶的數據表資源。

命令

名稱 Description 類型 狀態
az cosmosdb table create

在 Azure Cosmos DB 帳戶下建立數據表。

核心 GA
az cosmosdb table delete

刪除 Azure Cosmos DB 帳戶底下的數據表。

核心 GA
az cosmosdb table exists

檢查 Azure Cosmos DB 數據表是否存在。

核心 GA
az cosmosdb table list

列出 Azure Cosmos DB 帳戶底下的數據表。

核心 GA
az cosmosdb table restorable-resource

管理可在指定時間戳和區域之指定帳戶中還原的數據表。

核心和擴充功能 GA
az cosmosdb table restorable-resource list

列出可在指定時間戳和區域之指定帳戶中還原的所有數據表。

核心 GA
az cosmosdb table restorable-resource list (cosmosdb-preview 擴充功能)

列出可在指定時間戳和區域之指定帳戶中還原的所有數據表。

副檔名 預覽​​
az cosmosdb table restorable-table

管理可在 Azure Cosmos DB 帳戶中還原的不同數據表版本。

核心和擴充功能 GA
az cosmosdb table restorable-table list

列出在指定可還原帳戶中建立/修改/刪除的所有數據表版本。

核心 GA
az cosmosdb table restorable-table list (cosmosdb-preview 擴充功能)

列出在指定可還原帳戶中建立/修改/刪除的所有數據表版本。

副檔名 預覽​​
az cosmosdb table restore

還原相同帳戶內已刪除的數據表。

核心 GA
az cosmosdb table restore (cosmosdb-preview 擴充功能)

還原相同帳戶內已刪除的數據表。

副檔名 預覽​​
az cosmosdb table retrieve-latest-backup-time

擷取指定區域中指定數據表的最新可還原時間戳。

核心 GA
az cosmosdb table retrieve-latest-backup-time (cosmosdb-preview 擴充功能)

擷取指定區域中指定數據表的最新可還原時間戳。

副檔名 預覽​​
az cosmosdb table show

顯示 Azure Cosmos DB 帳戶下數據表的詳細數據。

核心 GA
az cosmosdb table throughput

管理 Azure Cosmos DB 帳戶下的數據表輸送量。

核心 GA
az cosmosdb table throughput migrate

在自動調整和手動布建之間移轉數據表的輸送量。

核心 GA
az cosmosdb table throughput show

取得 Azure Cosmos DB 帳戶下數據表的輸送量。

核心 GA
az cosmosdb table throughput update

更新 Azure Cosmos DB 帳戶下數據表的輸送量。

核心 GA

az cosmosdb table create

在 Azure Cosmos DB 帳戶下建立數據表。

az cosmosdb table create --account-name
                         --name
                         --resource-group
                         [--max-throughput]
                         [--throughput]

必要參數

--account-name -a

Cosmosdb 帳戶名稱。

--name -n

資料表名稱。

--resource-group -g

資源群組的名稱。 您可以使用 az configure --defaults group=<name> 來設定預設群組。

選擇性參數

--max-throughput

輸送量資源上限可以調整為 (RU/秒)。 提供資源啟用自動調整時。 最小值可以是 4000 (RU/秒)。

--throughput

數據表的輸送量(RU/秒)。 預設值為 400。

全域參數
--debug

增加記錄詳細資訊,以顯示所有偵錯記錄。

--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

--output -o

輸出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
預設值: json
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或識別碼。 您可以使用 來設定預設訂用 az account set -s NAME_OR_ID帳戶。

--verbose

增加記錄詳細資訊。 使用 --debug 來取得完整偵錯記錄。

az cosmosdb table delete

刪除 Azure Cosmos DB 帳戶底下的數據表。

az cosmosdb table delete --account-name
                         --name
                         --resource-group
                         [--yes]

必要參數

--account-name -a

Cosmosdb 帳戶名稱。

--name -n

資料表名稱。

--resource-group -g

資源群組的名稱。 您可以使用 az configure --defaults group=<name> 來設定預設群組。

選擇性參數

--yes -y

不提示確認。

預設值: False
全域參數
--debug

增加記錄詳細資訊,以顯示所有偵錯記錄。

--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

--output -o

輸出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
預設值: json
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或識別碼。 您可以使用 來設定預設訂用 az account set -s NAME_OR_ID帳戶。

--verbose

增加記錄詳細資訊。 使用 --debug 來取得完整偵錯記錄。

az cosmosdb table exists

檢查 Azure Cosmos DB 數據表是否存在。

az cosmosdb table exists --account-name
                         --name
                         --resource-group

必要參數

--account-name -a

Cosmosdb 帳戶名稱。

--name -n

資料表名稱。

--resource-group -g

資源群組的名稱。 您可以使用 az configure --defaults group=<name> 來設定預設群組。

全域參數
--debug

增加記錄詳細資訊,以顯示所有偵錯記錄。

--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

--output -o

輸出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
預設值: json
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或識別碼。 您可以使用 來設定預設訂用 az account set -s NAME_OR_ID帳戶。

--verbose

增加記錄詳細資訊。 使用 --debug 來取得完整偵錯記錄。

az cosmosdb table list

列出 Azure Cosmos DB 帳戶底下的數據表。

az cosmosdb table list --account-name
                       --resource-group

必要參數

--account-name -a

Cosmosdb 帳戶名稱。

--resource-group -g

資源群組的名稱。 您可以使用 az configure --defaults group=<name> 來設定預設群組。

全域參數
--debug

增加記錄詳細資訊,以顯示所有偵錯記錄。

--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

--output -o

輸出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
預設值: json
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或識別碼。 您可以使用 來設定預設訂用 az account set -s NAME_OR_ID帳戶。

--verbose

增加記錄詳細資訊。 使用 --debug 來取得完整偵錯記錄。

az cosmosdb table restore

還原相同帳戶內已刪除的數據表。

az cosmosdb table restore --account-name
                          --resource-group
                          --table-name
                          [--restore-timestamp]

範例

還原相同帳戶內已刪除的數據表。

az cosmosdb table restore --resource-group resource_group --account-name database_account_name --table-name name_of_table_needs_to_be_restored --restore-timestamp 2020-07-13T16:03:41+0000

必要參數

--account-name -a

Cosmosdb 帳戶名稱。

--resource-group -g

資源群組的名稱。 您可以使用 az configure --defaults group=<name> 來設定預設群組。

--table-name -n

CosmosDB 資料表名稱的名稱。

選擇性參數

--restore-timestamp -t

數據表必須還原至的時間戳。

全域參數
--debug

增加記錄詳細資訊,以顯示所有偵錯記錄。

--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

--output -o

輸出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
預設值: json
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或識別碼。 您可以使用 來設定預設訂用 az account set -s NAME_OR_ID帳戶。

--verbose

增加記錄詳細資訊。 使用 --debug 來取得完整偵錯記錄。

az cosmosdb table restore (cosmosdb-preview 擴充功能)

預覽

此命令處於預覽狀態,且正在開發中。 參考和支援層級: https://aka.ms/CLI_refstatus

還原相同帳戶內已刪除的數據表。

az cosmosdb table restore --account-name
                          --resource-group
                          --table-name
                          [--disable-ttl {false, true}]
                          [--restore-timestamp]

範例

還原相同帳戶內已刪除的數據表。

az cosmosdb table restore --resource-group resource_group --account-name database_account_name --table-name name_of_table_needs_to_be_restored --restore-timestamp 2020-07-13T16:03:41+0000

必要參數

--account-name -a

Cosmosdb 帳戶名稱。

--resource-group -g

資源群組的名稱。 您可以使用 az configure --defaults group=<name> 來設定預設群組。

--table-name -n

CosmosDB 資料表名稱的名稱。

選擇性參數

--disable-ttl
預覽

啟用或停用已停用ttl還原。

接受的值: false, true
--restore-timestamp -t

數據表必須還原至的時間戳。

全域參數
--debug

增加記錄詳細資訊,以顯示所有偵錯記錄。

--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

--output -o

輸出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
預設值: json
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或識別碼。 您可以使用 來設定預設訂用 az account set -s NAME_OR_ID帳戶。

--verbose

增加記錄詳細資訊。 使用 --debug 來取得完整偵錯記錄。

az cosmosdb table retrieve-latest-backup-time

擷取指定區域中指定數據表的最新可還原時間戳。

az cosmosdb table retrieve-latest-backup-time --account-name
                                              --location
                                              --resource-group
                                              --table-name

必要參數

--account-name -a

CosmosDB 資料庫帳戶的名稱。

--location -l

帳戶的位置。

--resource-group -g

資源群組的名稱。 您可以使用 az configure --defaults group=<name> 來設定預設群組。

--table-name -n

CosmosDB 資料表名稱的名稱。

全域參數
--debug

增加記錄詳細資訊,以顯示所有偵錯記錄。

--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

--output -o

輸出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
預設值: json
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或識別碼。 您可以使用 來設定預設訂用 az account set -s NAME_OR_ID帳戶。

--verbose

增加記錄詳細資訊。 使用 --debug 來取得完整偵錯記錄。

az cosmosdb table retrieve-latest-backup-time (cosmosdb-preview 擴充功能)

預覽

此命令處於預覽狀態,且正在開發中。 參考和支援層級: https://aka.ms/CLI_refstatus

擷取指定區域中指定數據表的最新可還原時間戳。

az cosmosdb table retrieve-latest-backup-time --account-name
                                              --location
                                              --resource-group
                                              --table-name

必要參數

--account-name -a

CosmosDB 資料庫帳戶的名稱。

--location -l

帳戶的位置。

--resource-group -g

資源群組的名稱。 您可以使用 az configure --defaults group=<name> 來設定預設群組。

--table-name -n

CosmosDB 資料表名稱的名稱。

全域參數
--debug

增加記錄詳細資訊,以顯示所有偵錯記錄。

--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

--output -o

輸出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
預設值: json
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或識別碼。 您可以使用 來設定預設訂用 az account set -s NAME_OR_ID帳戶。

--verbose

增加記錄詳細資訊。 使用 --debug 來取得完整偵錯記錄。

az cosmosdb table show

顯示 Azure Cosmos DB 帳戶下數據表的詳細數據。

az cosmosdb table show --account-name
                       --name
                       --resource-group

必要參數

--account-name -a

Cosmosdb 帳戶名稱。

--name -n

資料表名稱。

--resource-group -g

資源群組的名稱。 您可以使用 az configure --defaults group=<name> 來設定預設群組。

全域參數
--debug

增加記錄詳細資訊,以顯示所有偵錯記錄。

--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

--output -o

輸出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
預設值: json
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或識別碼。 您可以使用 來設定預設訂用 az account set -s NAME_OR_ID帳戶。

--verbose

增加記錄詳細資訊。 使用 --debug 來取得完整偵錯記錄。