table
Creates, updates, deletes, gets or lists a table resource.
Overview
| Name | table |
| Type | Resource |
| Id | azure.storage.table |
Fields
The following fields are returned by SELECT queries:
- get
- list
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
signedIdentifiers | array | List of stored access policies specified on the table. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tableName | string | Table name under the specified account. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
signedIdentifiers | array | List of stored access policies specified on the table. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tableName | string | Table name under the specified account. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | resource_group_name, account_name, table_name, subscription_id | Gets the table with the specified table name, under the specified account if it exists. | |
list | select | resource_group_name, account_name, subscription_id | Gets a list of all the tables under the specified storage account. | |
create | insert | resource_group_name, account_name, table_name, subscription_id | Creates a new table with the specified table name, under the specified account. | |
update | update | resource_group_name, account_name, table_name, subscription_id | Creates a new table with the specified table name, under the specified account. | |
delete | delete | resource_group_name, account_name, table_name, subscription_id | Deletes the table with the specified table name, under the specified account if it exists. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
account_name | string | The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. Required. |
resource_group_name | string | The name of the resource group. The name is case insensitive. Required. |
subscription_id | string | |
table_name | string | A table name must be unique within a storage account and must be between 3 and 63 characters.The name must comprise of only alphanumeric characters and it cannot begin with a numeric character. Required. |
SELECT examples
- get
- list
Gets the table with the specified table name, under the specified account if it exists.
SELECT
id,
name,
signedIdentifiers,
systemData,
tableName,
type
FROM azure.storage.table
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND account_name = '{{ account_name }}' -- required
AND table_name = '{{ table_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Gets a list of all the tables under the specified storage account.
SELECT
id,
name,
signedIdentifiers,
systemData,
tableName,
type
FROM azure.storage.table
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND account_name = '{{ account_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
INSERT examples
- create
- Manifest
Creates a new table with the specified table name, under the specified account.
INSERT INTO azure.storage.table (
properties,
resource_group_name,
account_name,
table_name,
subscription_id
)
SELECT
'{{ properties }}',
'{{ resource_group_name }}',
'{{ account_name }}',
'{{ table_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
properties,
systemData,
type
;
# Description fields are for documentation purposes
- name: table
props:
- name: resource_group_name
value: "{{ resource_group_name }}"
description: Required parameter for the table resource.
- name: account_name
value: "{{ account_name }}"
description: Required parameter for the table resource.
- name: table_name
value: "{{ table_name }}"
description: Required parameter for the table resource.
- name: subscription_id
value: "{{ subscription_id }}"
description: Required parameter for the table resource.
- name: properties
description: |
Table resource properties.
value:
tableName: "{{ tableName }}"
signedIdentifiers:
- id: "{{ id }}"
accessPolicy:
startTime: "{{ startTime }}"
expiryTime: "{{ expiryTime }}"
permission: "{{ permission }}"
UPDATE examples
- update
Creates a new table with the specified table name, under the specified account.
UPDATE azure.storage.table
SET
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND account_name = '{{ account_name }}' --required
AND table_name = '{{ table_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
properties,
systemData,
type;
DELETE examples
- delete
Deletes the table with the specified table name, under the specified account if it exists.
DELETE FROM azure.storage.table
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND account_name = '{{ account_name }}' --required
AND table_name = '{{ table_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;