Splunk Search

both stats and timechart gives different values

splunkuseradmin
Path Finder

Hi all
I was wondering if i can get some help in this. as I have some fields in stats and i want span=1w of that.
when I use ....|timechart sapn=1w give me different values than in stats.
I juss want those stats values to be shown by week.

thanks

Tags (1)
0 Karma

arjunpkishore5
Motivator

For binning stats, do this

|bucket span=1w _time
|stats your_aggregations by _time, your_grouping_fields

0 Karma

kmaron
Motivator

you can add a 1 week span to your stats like this

| bucket _time span=1w

and then add _time to the by callMediaType for your stats command.

also, your stats has a by callMediaType but you did not include that in your timechart. This in and of itself would make the results different. Is that on purpose?

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...