Skip to main content

snapshots

Creates, updates, deletes, gets or lists a snapshots resource.

Overview

Namesnapshots
TypeResource
Idazure.container_storage.snapshots

Fields

NameDatatypeDescription
poolNametextfield from the properties object
provisioning_statetextfield from the properties object
resourceGroupNametextfield from the properties object
snapshotNametextfield from the properties object
sourcetextfield from the properties object
statustextfield from the properties object
subscriptionIdtextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECTpoolName, resourceGroupName, snapshotName, subscriptionIdGet a Snapshot
list_by_poolSELECTpoolName, resourceGroupName, subscriptionIdList Snapshot resources by Pool
create_or_updateINSERTpoolName, resourceGroupName, snapshotName, subscriptionIdCreate a Snapshot
deleteDELETEpoolName, resourceGroupName, snapshotName, subscriptionIdDelete a Snapshot

SELECT examples

List Snapshot resources by Pool

SELECT
poolName,
provisioning_state,
resourceGroupName,
snapshotName,
source,
status,
subscriptionId
FROM azure.container_storage.vw_snapshots
WHERE poolName = '{{ poolName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';

INSERT example

Use the following StackQL query and manifest file to create a new snapshots resource.

/*+ create */
INSERT INTO azure.container_storage.snapshots (
poolName,
resourceGroupName,
snapshotName,
subscriptionId,
properties
)
SELECT
'{{ poolName }}',
'{{ resourceGroupName }}',
'{{ snapshotName }}',
'{{ subscriptionId }}',
'{{ properties }}'
;

DELETE example

Deletes the specified snapshots resource.

/*+ delete */
DELETE FROM azure.container_storage.snapshots
WHERE poolName = '{{ poolName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND snapshotName = '{{ snapshotName }}'
AND subscriptionId = '{{ subscriptionId }}';