Skip to main content

top_query_statistics

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

Overview

Nametop_query_statistics
TypeResource
Idazure.maria_db.top_query_statistics

Fields

NameDatatypeDescription
aggregation_functiontextfield from the properties object
database_namestextfield from the properties object
end_timetextfield from the properties object
metric_display_nametextfield from the properties object
metric_nametextfield from the properties object
metric_valuetextfield from the properties object
metric_value_unittextfield from the properties object
queryStatisticIdtextfield from the properties object
query_execution_counttextfield from the properties object
query_idtextfield from the properties object
resourceGroupNametextfield from the properties object
serverNametextfield from the properties object
start_timetextfield from the properties object
subscriptionIdtextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECTqueryStatisticId, resourceGroupName, serverName, subscriptionIdRetrieve the query statistic for specified identifier.
list_by_serverSELECTresourceGroupName, serverName, subscriptionId, data__propertiesRetrieve the Query-Store top queries for specified metric and aggregation.

SELECT examples

Retrieve the query statistic for specified identifier.

SELECT
aggregation_function,
database_names,
end_time,
metric_display_name,
metric_name,
metric_value,
metric_value_unit,
queryStatisticId,
query_execution_count,
query_id,
resourceGroupName,
serverName,
start_time,
subscriptionId
FROM azure.maria_db.vw_top_query_statistics
WHERE queryStatisticId = '{{ queryStatisticId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND serverName = '{{ serverName }}'
AND subscriptionId = '{{ subscriptionId }}';