Splunk Search

Only show every 7th day in timechart

akhan8928
New Member

Currently I have the following -

index="mysql_uc_orders" earliest=-7d@d latest=now | bucket span=1m _time | timechart count span=30m | timewrap d

This works fine as it shows the latest day and the 7th day but it also shows 1day, 2days, 3days etc.

I'd like to only show the latest day and the 7 days before (I.e. week over week on a specific day).

Does anyone know what filter I need to use?

Tags (1)
0 Karma

lguinn2
Legend

With timewrap, I think you want timewrap w not d.

You could also do this manually. Here is another way

index="mysql_uc_orders" earliest=-7d@d latest=now 
| bucket span=1m _time 
| timechart count span=30m
| eval today=strftime(now(),"%A")
| eval dayOfWeek = strftime(_time,"%A")
| where dayOfWeek == today
0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...