Splunk Search

Need some help with Syntax

MBerikcurtis
Path Finder

I like to show results only for times between 7pm and 7am Monday through Friday OR anytime on Saturday or Sunday. I'd like to do this within the same search.

I'm using:

(date_wday="s*" OR (date_hour > 19 AND date_hour < 7))
Tags (2)
0 Karma
1 Solution

Ayn
Legend

date_hour can't both be more than 19 and less than 7 at the same time. You probably want OR instead of AND there.

View solution in original post

Ayn
Legend

date_hour can't both be more than 19 and less than 7 at the same time. You probably want OR instead of AND there.

MBerikcurtis
Path Finder

Perfect! Can't believe I missed that.

0 Karma
Get Updates on the Splunk Community!

Enterprise Security Content Update (ESCU) | New Releases

In December, the Splunk Threat Research Team had 1 release of new security content via the Enterprise Security ...

Why am I not seeing the finding in Splunk Enterprise Security Analyst Queue?

(This is the first of a series of 2 blogs). Splunk Enterprise Security is a fantastic tool that offers robust ...

Index This | What are the 12 Days of Splunk-mas?

December 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...