Reporting

Possible to redefine @w to start on different day?

Jason
Motivator

A client would like a bunch of reports, written with -1w@w and @w week-snapping, to start on Monday morning instead of Sunday morning. Is it possible to change what @w snaps to?

1 Solution

rroberts
Splunk Employee
Splunk Employee

Yes, you can use...

w0 = Sunday w1 = Monday etc...

example: earliest=@w0 
 Searches from the current time to the previous Sun

View solution in original post

rroberts
Splunk Employee
Splunk Employee

Yes, you can use...

w0 = Sunday w1 = Monday etc...

example: earliest=@w0 
 Searches from the current time to the previous Sun

rroberts
Splunk Employee
Splunk Employee

Snippet from http://www.splunk.com/base/Documentation/4.1.4/User/ChangeTheTimeRangeOfYourSearch

Note: The abbreviations w0, w1, w2, w3, w4, w5 and w6 are reserved for specifying "snap to" days of the week; where w0 is Sunday, w1 is Monday, etc. When you snap to a week, @w or @week, it is equivalent to snapping to Sunday or @w0.

Note: When you specify @q, @qtr, or @quarter, it snaps to the beginning of the most recent quarter: Jan 1, Apr 1, July 1, or Oct 1.

0 Karma

rroberts
Splunk Employee
Splunk Employee

By the way I usually use ...-7d instead of -1w.

0 Karma
Get Updates on the Splunk Community!

Join Us for Splunk University and Get Your Bootcamp Game On!

If you know, you know! Splunk University is the vibe this summer so register today for bootcamps galore ...

.conf24 | Learning Tracks for Security, Observability, Platform, and Developers!

.conf24 is taking place at The Venetian in Las Vegas from June 11 - 14. Continue reading to learn about the ...

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...