Splunk Search

[Inquiry]: Retrieving search results with schedule timings

dcresido
New Member

Hi everyone,

Good day!

I would like to ask about my search query below.

index="myIndex" source IN(*MyLogs*) host=server*
    | append
      [search "Missing process" 
      | eval myTime = _time
      | eval myHour=strftime(_time, "%H") 
      | eval myMinute=strftime(_time, "%M") 
      ]
        | search  ((myHour>=7 AND myMinute>=31) AND (myHour<=14 AND myMinute<=59))

And this is my use case: How can I retrieve search event from 7:31AM to 4:29PM from my search query?

Everytime I tried using the query above, I was able to retrieve some results if I use something like this

| search  ((myHour>=7 AND myMinute>=31) AND (myHour<=14 AND myMinute<=59))

But if I changed it to something like this

| search  ((myHour>=7 AND myMinute>=31) AND (myHour<=14 AND myMinute<=29))

I can no longer see any results. It seems that I do have some issues in assigning the minute parameters on this search query. But I'm not sure how to fix it.

Will you be able to provide some insights on how can I achieve my use case above?

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