Edit

Share via


Queries for the DataSetRuns table

For information on using these queries in the Azure portal, see Log Analytics tutorial. For the REST API, see Query.

Latest Data Collection Rule Conditional Data Set Output

Displays the output of the latest successful Data Collection Rule (DCR) based conditional data set.

let latestSuccessfulDataSetRun =
DataSetRuns
| where Status == "DataSetRunSucceeded"
| order by TimeGenerated desc
| project DataSetRunId
| take 1;
DataSetOutput
| where DataSetRunId in (latestSuccessfulDataSetRun)
| order by DataSetRunSeqNum asc