I have in the Splunk logs messages with the following format:
LogService product id=1 price=10.00 numberOfClients=4 profit=5.00
I need to create a query that will find all the records from the last day and will calculate:
sum(price * numberOfClients)/sum(profit),
and will trigger alerts if the result is not within [0.2, 0.8], where sum is the sum of the values for all the logged messages.
I have tried several ways of doing it, but it didn't work. Please advise.