Splunk Search

hide column where value = 0

BaptVe
Path Finder

Hello everyone !

I've two panels depending on time (timechart) :
1)

 index=XXX sourcetype="XXXXX" Severity="*" |timechart count(Severity) span=6h

On the picture, this one is right : it only shows between the two times where there is values and hide if the last days where there is no value ! (there is nothing between now and the 4 may at 14:00)
Severity last 7 days

2)

index=XXX sourcetype="XXXXX" Severity="CRITICAL" |timechart count as CRIT span=6h
| appendcols [search
index=XXX sourcetype="XXXXX" Severity="FATAL" |timechart count as FATAL span=6h ]
| appendcols [search 
index=XXX sourcetype="XXXXX" Severity="WARNING" |timechart count as WARN span=6h ]
| table CRIT, FATAL, WARN, _time

On the second graph, it shows the values between now and the 4 may at 14:00 and marks them as 0. I want to hide these values (and make the graph auto resize like the previous one if possible) because these are not relevant and i want to keep the same time range for both graphs :
Severity by Values last 7 days

Thanks for your help !

0 Karma
1 Solution

jplumsdaine22
Influencer

Why not condense the search?

index=XXX sourcetype="XXXXX" (Severity="CRITICAL" OR Severity="WARNING" OR Severity="FATAL") |timechart span=6h count by Severity | rename WARNING AS WARN | rename CRITICAL AS CRIT

View solution in original post

jplumsdaine22
Influencer

Why not condense the search?

index=XXX sourcetype="XXXXX" (Severity="CRITICAL" OR Severity="WARNING" OR Severity="FATAL") |timechart span=6h count by Severity | rename WARNING AS WARN | rename CRITICAL AS CRIT

BaptVe
Path Finder

It was what i was looking for !

Thanks 🙂

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.
Get Updates on the Splunk Community!

Tech Talk Recap | Mastering Threat Hunting

Mastering Threat HuntingDive into the world of threat hunting, exploring the key differences between ...

Observability for AI Applications: Troubleshooting Latency

If you’re working with proprietary company data, you’re probably going to have a locally hosted LLM or many ...

Splunk AI Assistant for SPL vs. ChatGPT: Which One is Better?

In the age of AI, every tool promises to make our lives easier. From summarizing content to writing code, ...