Splunk Search

fill chart x-axis if data is missing

hunyady
Explorer

Hi,
I have a search, want to show two lines of counts by min in a chart. Want to have value 0 if there is no result in some minute.
i.E.
time typ=A typ=B
12:30 100 110
12:31 100 ---
12:32 --- ---
12:33 40 50
etc.
I want to have the values of "0" at 12:32 too in my graph.
other problem:
By chart is "span=1m" not accepted, I don't have result by "chart count by typ span=1m" only by "chart count by typ"
thank you

Tags (2)
0 Karma

woodcock
Esteemed Legend

Your text is extremely difficult to understand but maybe this is what you seek:

... | timechart span=1m count by type
0 Karma

richgalloway
SplunkTrust
SplunkTrust

Try

... | chart cont=false count by typ

or

... | fillnull value=0 typ | chart count by typ
---
If this reply helps you, Karma would be appreciated.
0 Karma
Get Updates on the Splunk Community!

ATTENTION!! We’re MOVING (not really)

Hey, all! In an effort to keep this Slack workspace secure and also to make our new members' experience easy, ...

Splunk Admins: Build a Smarter Stack with These Must-See .conf25 Sessions

  Whether you're running a complex Splunk deployment or just getting your bearings as a new admin, .conf25 ...

AppDynamics Summer Webinars

This summer, our mighty AppDynamics team is cooking up some delicious content on YouTube Live to satiate your ...