Splunk Search

Difference of values ​​using single value with percentage

leandromatperei
Path Finder

I would like to put together a graph with the difference of values ​​as a percentage, so I can use the single value and if it is above 70% it would turn red.

 

 

 

index="teste" "ProcessInboundEmail" | timechart span=10m dc(id_email) as ProcessInboundEmail
| appendcols  [search index="teste""submitInboundEmail" ended | timechart span=10m dc(id_email) as submitInboundEmail]
| eval diff =  ProcessInboundEmail - submitInboundEmail | eval diff=if(ProcessInboundEmail< submitInboundEmail, diff * -1, diff)

 

 

 

 

can you help me?

 

Labels (1)
Tags (1)
0 Karma
1 Solution

to4kawa
Ultra Champion

index="teste" "ProcessInboundEmail" | timechart span=10m dc(id_email) as ProcessInboundEmail
| appendcols [search index="teste""submitInboundEmail" ended | timechart span=10m dc(id_email) as submitInboundEmail]
| eval perc = round(abs(ProcessInboundEmail - submitInboundEmail)/(ProcessInboundEmail + submitInboundEmail)*100,2) | table _time perc

 

and modify FORMAT

View solution in original post

0 Karma

to4kawa
Ultra Champion

index="teste" "ProcessInboundEmail" | timechart span=10m dc(id_email) as ProcessInboundEmail
| appendcols [search index="teste""submitInboundEmail" ended | timechart span=10m dc(id_email) as submitInboundEmail]
| eval perc = round(abs(ProcessInboundEmail - submitInboundEmail)/(ProcessInboundEmail + submitInboundEmail)*100,2) | table _time perc

 

and modify FORMAT

0 Karma
Get Updates on the Splunk Community!

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...