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!

Webinar Recap | Revolutionizing IT Operations: The Transformative Power of AI and ML ...

The Transformative Power of AI and ML in Enhancing Observability   In the realm of IT operations, the ...

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...