If you know all container names in advance, simply enumerate them. One way to do this is to use foreach. index=* Initialised xxxxxxxxxxxx xxxxxx |rex "\{consumerName\=\'(MY REGEX)"
| stats coun...
See more...
If you know all container names in advance, simply enumerate them. One way to do this is to use foreach. index=* Initialised xxxxxxxxxxxx xxxxxx |rex "\{consumerName\=\'(MY REGEX)"
| stats count as Connections by Container_Name
| transpose header_field=Container_Name column_name=Container_Name
| foreach "Container A", "Container B", "Container C", "Container D"
[eval <<FIELD>> = if(isnull('<<FIELD>>'), "(missing)", '<<FIELD>>')]
| transpose header_field=Container_Name column_name=Container_Name
| addcoltotals fieldname=Connections labelfield=Container_Name (If you perform stats on Container_Name, For example, if your data is missing "Container D", you get Container_Name Connections Container A 1 Container B 1 Container C 1 Container D (missing) Total 3 If your data is missing "Container C", you get Container_Name Connections Container A 1 Container B 1 Container D 1 Container C (missing) Total 3 And so on. Here is an emulation for you to play with and compare with real data | makeresults
| fields - _time
| eval Container_Name = mvappend("Container A", "Container B"```, "Container C"```, "Container D")
``` data emulation above ```