Splunk Search

Search Time interval

shirolu
Explorer

hello

I have a search problem

I would like to set a time interval

Interval last Monday to last Sunday

if today is 2010/05/31

Time interval 2010/5/24 ~ 2010/5/30 (last Monday ~ last Sunday)

if today is 2010/06/04

Time interval 2010/5/24 ~ 2010/5/30 (last Monday ~ last Sunday)

Time interval will always be last Monday ~ last Sunday

How am I going to set

Thank you for your help

CT

0 Karma

shirolu
Explorer

hi ~ all

Problems have been solved

Thank you for your help

CT

0 Karma

sideview
SplunkTrust
SplunkTrust

it's better to accept or upvote the answer rather than posting a second answer saying your issue has been solved.

0 Karma

gkanapathy
Splunk Employee
Splunk Employee
earliest=-1w@w1 latest=@w0

http://www.splunk.com/base/Documentation/latest/User/ChangeTheTimeRangeOfYourSearch#Specify_relative...

Update: actually, you probably want to go from Monday till the end of Sunday, i.e., the beginning of this Monday, so actually:

earliest=-1w@w1 latest=@w1

is probably more like what you want.

Get Updates on the Splunk Community!

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 ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...