queries
Creates, updates, deletes, gets or lists a queries
resource.
Overview
Name | queries |
Type | Resource |
Id | azure.log_analytics.queries |
Fields
- vw_queries
- queries
Name | Datatype | Description |
---|---|---|
id | text | Azure resource Id |
name | text | Azure resource name |
description | text | field from the properties object |
author | text | field from the properties object |
body | text | field from the properties object |
display_name | text | field from the properties object |
properties | text | Properties that define an Log Analytics QueryPack-Query resource. |
queryPackName | text | field from the properties object |
related | text | field from the properties object |
resourceGroupName | text | field from the properties object |
subscriptionId | text | field from the properties object |
system_data | text | field from the properties object |
tags | text | field from the properties object |
time_created | text | field from the properties object |
time_modified | text | field from the properties object |
type | text | Azure resource type |
Name | Datatype | Description |
---|---|---|
id | string | Azure resource Id |
name | string | Azure resource name |
properties | object | Properties that define an Log Analytics QueryPack-Query resource. |
systemData | object | Read only system data |
type | string | Azure resource type |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | id, queryPackName, resourceGroupName, subscriptionId | Gets a specific Log Analytics Query defined within a Log Analytics QueryPack. |
list | SELECT | queryPackName, resourceGroupName, subscriptionId | Gets a list of Queries defined within a Log Analytics QueryPack. |
delete | DELETE | id, queryPackName, resourceGroupName, subscriptionId | Deletes a specific Query defined within an Log Analytics QueryPack. |
update | UPDATE | id, queryPackName, resourceGroupName, subscriptionId | Adds or Updates a specific Query within a Log Analytics QueryPack. |
put | REPLACE | id, queryPackName, resourceGroupName, subscriptionId | Adds or Updates a specific Query within a Log Analytics QueryPack. |
search | EXEC | queryPackName, resourceGroupName, subscriptionId | Search a list of Queries defined within a Log Analytics QueryPack according to given search properties. |
SELECT
examples
Gets a list of Queries defined within a Log Analytics QueryPack.
- vw_queries
- queries
SELECT
id,
name,
description,
author,
body,
display_name,
properties,
queryPackName,
related,
resourceGroupName,
subscriptionId,
system_data,
tags,
time_created,
time_modified,
type
FROM azure.log_analytics.vw_queries
WHERE queryPackName = '{{ queryPackName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
SELECT
id,
name,
properties,
systemData,
type
FROM azure.log_analytics.queries
WHERE queryPackName = '{{ queryPackName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
UPDATE
example
Updates a queries
resource.
/*+ update */
UPDATE azure.log_analytics.queries
SET
properties = '{{ properties }}'
WHERE
id = '{{ id }}'
AND queryPackName = '{{ queryPackName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
REPLACE
example
Replaces all fields in the specified queries
resource.
/*+ update */
REPLACE azure.log_analytics.queries
SET
properties = '{{ properties }}'
WHERE
id = '{{ id }}'
AND queryPackName = '{{ queryPackName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
DELETE
example
Deletes the specified queries
resource.
/*+ delete */
DELETE FROM azure.log_analytics.queries
WHERE id = '{{ id }}'
AND queryPackName = '{{ queryPackName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';