Splunk Search

How to create a pie chart after applying math on column values extracted?

sjs
Path Finder

Hey people, my requirement is as such

sjs_0-1673583059201.png

 

I have extracted these columns from my data using the query 

my query | rex "filterExecutionTime=(?<FET>[^,]+)" | rex "ddbWriteExecutionTime=(?<ddbET>[^)]+)" | rex "EXECUTION_TIME : (?<totalTime>[^ ms]+)" | eval buildAndTearDowTime=(tonumber(FET)) + (tonumber(ddbET)) |table totalTime FET ddbET buildAndTearDownTime

 

 

I want to have buildAndTearDown as totalTime - (FET+ ddbET)

 

once I have all the three values required (FET, ddbET, buildAndTearDown) I want to put these values in a pie chart.

 

Another question I have is why is 

This statement 

eval buildAndTearDowTime=(tonumber(FET)) + (tonumber(ddbET))

is giving me null value

 

Thanks 😊 

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

bowesmana
SplunkTrust
SplunkTrust

To make the pie chart, do

| table FET ddbET buildAndTearDownTime
| transpose 0

View solution in original post

sjs
Path Finder

OMG, that worked as charm

sjs_0-1673584065216.png

 

can I add any legends about the time on to the right side or somewhere because ddbET is so small, it is not visible

0 Karma

sjs
Path Finder

Thanks that was so silly of me, could you please help me on the pie chart part too

 

0 Karma

bowesmana
SplunkTrust
SplunkTrust

To make the pie chart, do

| table FET ddbET buildAndTearDownTime
| transpose 0

bowesmana
SplunkTrust
SplunkTrust

You have spelt buildAndTearDownTime incorrectly

| eval buildAndTearDowTime=(tonumber(FET)) + (tonumber(ddbET)) 

missing n in Down

0 Karma
Get Updates on the Splunk Community!

Platform Newsletter Highlights | March 2023

 March 2023 | Check out the latest and greatestIntroducing Splunk Edge Processor, simplified data ...

Enterprise Security Content Updates (ESCU) - New Releases

In the last month, the Splunk Threat Research Team (STRT) has had 3 releases of new content via the Enterprise ...

Thought Leaders are Validating Your Hard Work and Training Rigor

As a Splunk enthusiast and member of the Splunk Community, you are one of thousands who recognize the value of ...