Splunk Search

Removing a line from a timechart?

thefosk
Engager

Within our application we are tracking a "Pings" metric, and in our query we are showing pings over time along with a metric called "instances" that's calculated in real-time by dividing "Pings" by 24:

index="helloworld" metric="ping" | timechart count as Pings span=1d | eval Instances=floor(Pings/24)

This query has the result of showing both "Pings" and "Instances" in the timechart. How can we only display "Instances" and remove the "Pings" line?

Tags (3)
0 Karma
1 Solution

Richfez
SplunkTrust
SplunkTrust

Just remove it with the fields command at the end of your search.

... | fields - Pings

That should remove "Pings" but leave all else.

View solution in original post

Richfez
SplunkTrust
SplunkTrust

Just remove it with the fields command at the end of your search.

... | fields - Pings

That should remove "Pings" but leave all else.

Get Updates on the Splunk Community!

Updated Team Landing Page in Splunk Observability

We’re making some changes to the team landing page in Splunk Observability, based on your feedback. The ...

New! Splunk Observability Search Enhancements for Splunk APM Services/Traces and ...

Regardless of where you are in Splunk Observability, you can search for relevant APM targets including service ...

Webinar Recap | Revolutionizing IT Operations: The Transformative Power of AI and ML ...

The Transformative Power of AI and ML in Enhancing Observability   In the realm of IT operations, the ...