Skip to main content

instances

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

Overview

Nameinstances
TypeResource
Idazure.iot_orchestrator.instances

Fields

NameDatatypeDescription
nametextfield from the properties object
extended_locationtextfield from the properties object
locationtextThe geo-location where the resource lives
provisioning_statetextfield from the properties object
reconciliation_policytextfield from the properties object
resourceGroupNametextfield from the properties object
scopetextfield from the properties object
solutiontextfield from the properties object
subscriptionIdtextfield from the properties object
tagstextResource tags.
targettextfield from the properties object
versiontextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECTname, resourceGroupName, subscriptionIdGet a Instance
list_by_resource_groupSELECTresourceGroupName, subscriptionIdList Instance resources by resource group
list_by_subscriptionSELECTsubscriptionIdList Instance resources by subscription ID
create_or_updateINSERTname, resourceGroupName, subscriptionId, data__extendedLocationCreate a Instance
deleteDELETEname, resourceGroupName, subscriptionIdDelete a Instance
updateUPDATEname, resourceGroupName, subscriptionIdUpdate a Instance

SELECT examples

List Instance resources by subscription ID

SELECT
name,
extended_location,
location,
provisioning_state,
reconciliation_policy,
resourceGroupName,
scope,
solution,
subscriptionId,
tags,
target,
version
FROM azure.iot_orchestrator.vw_instances
WHERE subscriptionId = '{{ subscriptionId }}';

INSERT example

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

/*+ create */
INSERT INTO azure.iot_orchestrator.instances (
name,
resourceGroupName,
subscriptionId,
data__extendedLocation,
properties,
extendedLocation,
tags,
location
)
SELECT
'{{ name }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ data__extendedLocation }}',
'{{ properties }}',
'{{ extendedLocation }}',
'{{ tags }}',
'{{ location }}'
;

UPDATE example

Updates a instances resource.

/*+ update */
UPDATE azure.iot_orchestrator.instances
SET
tags = '{{ tags }}'
WHERE
name = '{{ name }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';

DELETE example

Deletes the specified instances resource.

/*+ delete */
DELETE FROM azure.iot_orchestrator.instances
WHERE name = '{{ name }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';