_sourceCategory=myService
| json field=_raw "log.Log" as log_message
| json field=_raw "log.Barcode" as log_Barcode
| json field=_raw "log.MachineId" as machine_id
| where log_message contains "successfully sorted"
| count by machine_id
This query will give me the successful count per machine ID.
What I want is to get all the messages in the last 24 hours and get the average success rate per hour.
so instead of having
Machine ID | Success Rate Count | TIME |
---|---|---|
123445 | 2400 | 24H |
I get something like
Machine ID | Success Rate Count per Hour | TIME |
---|---|---|
123445 | 100 | 24H |