Splunk Search

data query

DTERM
Contributor

index="named" 'earliest="@d-1h latest=@d+11'"

I'm trying to get all events that happened yesterday between 11 AM and 11 PM using the above search. It does not return any responses. What is it missing?

TIA

Tags (1)
1 Solution

zsimic
Path Finder

Looks like your quotes are wrong, and didn't specify earlest/latest correctly try this:

index="named" earliest=@d-13h latest=@d-1h

Or, if you prefer to have quotes everywhere:

index="named" earliest="@d-13h" latest="@d-1h"

If you meant "between yesterday 11 PM and today 11 AM", then try this (same as yours, just quotes corrected):

index="main" earliest="@d-1h" latest="@d+11h"

Hope this helps 🙂

View solution in original post

zsimic
Path Finder

Looks like your quotes are wrong, and didn't specify earlest/latest correctly try this:

index="named" earliest=@d-13h latest=@d-1h

Or, if you prefer to have quotes everywhere:

index="named" earliest="@d-13h" latest="@d-1h"

If you meant "between yesterday 11 PM and today 11 AM", then try this (same as yours, just quotes corrected):

index="main" earliest="@d-1h" latest="@d+11h"

Hope this helps 🙂

Get Updates on the Splunk Community!

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer at Splunk .conf24 ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...

Share Your Ideas & Meet the Lantern team at .Conf! Plus All of This Month’s New ...

Splunk Lantern is Splunk’s customer success center that provides advice from Splunk experts on valuable data ...