I am unable to read comma separated string field by bosun elastic search operation, however it works fine for numeric field. I want to read a field has comma separated strings, then I want to put it in template subject and notify to slack channel.
Below how I read numeric value but same not working string, I want to read a field called "tags" that has comma separated values of string like "test,poc,custa,maria"
$q = esstat(esls("metrics-xxx"), "host", esquery("metric", "disk"), "used_percent", "avg", "1m", "7m", "") $val = avg($q)
Anyone worked on that?
I'm not sure I'm entirely clear on question. Few things to keep in mind:
That being said if all you want to do is display it in the template, you can use either
.ESQueryor.ESQueryAllto get the raw rows, and you display the .Tag field of some sample rows from your query (or maybe just the first row). See usage of these template functions in the docs.