Skip to main content

azure_monitor_workspaces

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

Overview

Nameazure_monitor_workspaces
TypeResource
Idazure.monitor.azure_monitor_workspaces

Fields

NameDatatypeDescription
etagstringResource entity tag (ETag)
locationstringThe geo-location where the resource lives
propertiesobjectResource properties
tagsobjectResource tags.

Methods

NameAccessible byRequired ParamsDescription
getSELECTazureMonitorWorkspaceName, resourceGroupName, subscriptionIdReturns the specified Azure Monitor Workspace
list_by_resource_groupSELECTresourceGroupName, subscriptionIdLists all Azure Monitor Workspaces in the specified resource group
list_by_subscriptionSELECTsubscriptionIdLists all Azure Monitor Workspaces in the specified subscription
createINSERTazureMonitorWorkspaceName, resourceGroupName, subscriptionId, data__locationCreates or updates an Azure Monitor Workspace
deleteDELETEazureMonitorWorkspaceName, resourceGroupName, subscriptionIdDeletes an Azure Monitor Workspace
updateUPDATEazureMonitorWorkspaceName, resourceGroupName, subscriptionIdUpdates part of an Azure Monitor Workspace

SELECT examples

Lists all Azure Monitor Workspaces in the specified subscription

SELECT
etag,
location,
properties,
tags
FROM azure.monitor.azure_monitor_workspaces
WHERE subscriptionId = '{{ subscriptionId }}';

INSERT example

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

/*+ create */
INSERT INTO azure.monitor.azure_monitor_workspaces (
azureMonitorWorkspaceName,
resourceGroupName,
subscriptionId,
data__location,
properties,
tags,
location
)
SELECT
'{{ azureMonitorWorkspaceName }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ data__location }}',
'{{ properties }}',
'{{ tags }}',
'{{ location }}'
;

UPDATE example

Updates a azure_monitor_workspaces resource.

/*+ update */
UPDATE azure.monitor.azure_monitor_workspaces
SET
tags = '{{ tags }}'
WHERE
azureMonitorWorkspaceName = '{{ azureMonitorWorkspaceName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';

DELETE example

Deletes the specified azure_monitor_workspaces resource.

/*+ delete */
DELETE FROM azure.monitor.azure_monitor_workspaces
WHERE azureMonitorWorkspaceName = '{{ azureMonitorWorkspaceName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';