Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to create comments in Azure Log Analytics

I'm trying to create comments in my Azure Log Analytics queries and I'm stumped. Part of my challenge I think is treating this system as if it were SQL, which it is clearly not. using "--" for instance results in a syntax error

traces 
| where severityLevel > 1
-- this is an example of a line comment
| where message !contains "DiagnosticsLogger.GetMethod contains message 1"  
| where message !contains "DiagnosticsLogger.GetMethod contains message 2"
| summarize by timestamp, message, severityLevel

Couldn't find anything for search term "Comment" either on the https://docs.loganalytics.io reference.

like image 710
Matthew Thurston Avatar asked Dec 04 '17 20:12

Matthew Thurston


1 Answers

// works for Azure Log Analytics queries

like image 175
Pranshu Gupta Avatar answered Oct 21 '22 09:10

Pranshu Gupta