Splunk Search

Isolate date by adding greater than or equal to

luna
Explorer

Hi,

So my search window is from Feb 19 - Feb 23. I would like to have isolate Feb 19 - to have my events start on this date. My time range give me all the dates, but I would like to have them start with Feb 19 and two days after, but still keeping my time range search Feb 19 - Feb 23. 

I am using the where clause Feb_19>=PlayTime because I would like to have the events starting on Feb_19. Is my concept correct? I just need to start on the Feb_19 using less than or greater than equal to. 

(index="Example") OR (index="Blah")

| eval SundayTime=case(area="23", effortsTimeStamp),

PlayTime=case(eventType="Fun", loggedHrofEvent)

| eval date="2021-02-19 00:00:00.00"

| eval Feb19=strptime(date,"%Y-%m-%d %H:%M:%S.%6N")

| eval Feb_19=strftime(Feb19,"%Y-%m-%d %H:%M:%S")

| stats values(documents) as documents, values(index) as index, latest(PlayTime) as PlayTime latest(SundayTime) as SundayTime values(Feb_19) as Feb_19 by orders

| where isnull(PlayTime) AND Feb_19>=PlayTime

 

Labels (1)
0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Splunk Community Badges!

  Hey everyone! Ready to earn some serious bragging rights in the community? Along with our existing badges ...

How to find the worst searches in your Splunk environment and how to fix them

Everyone knows Splunk is a powerful platform for running searches and doing data analytics. Your ...

Share Your Feedback: On Admin Config Service (ACS)!

Help Us Build a Better Admin Config Service Experience (ACS)   We Want Your Feedback on Admin Config Service ...