Getting Data In

I have a Report running on cron schedule but want to exclude running on federal holidays

gnshah12345
Observer

I have created a csv file with dates of federal holidays.
holiday_date
01/01/19
01/21/19

I am trying to run my search like below.
index=appxindex |eval today_date=strftime(_time,"%m/%d/%y") | search NOT [|inputlookup exclude_holidays.csv holiday_date as today_date ]
The above is not working. All I want to do is if today_date = holiday_date (in csv file), I do not want to search. Any ideas?

Tags (1)
0 Karma

renjith_nair
Legend

@gnshah12345 ,

inputlookup doesnt have AS clause.

Try

index=appxindex |eval holiday_date=strftime(_time,"%m/%d/%y") 
| search NOT [|inputlookup exclude_holidays.csv|fields holiday_date]

OR

index=appxindex |eval today_date=strftime(_time,"%m/%d/%y") 
| search NOT [|inputlookup exclude_holidays.csv|rename holiday_date as today_date ]
---
What goes around comes around. If it helps, hit it with Karma 🙂
0 Karma
Get Updates on the Splunk Community!

Index This | Why did the turkey cross the road?

November 2025 Edition  Hayyy Splunk Education Enthusiasts and the Eternally Curious!   We’re back with this ...

Enter the Agentic Era with Splunk AI Assistant for SPL 1.4

  🚀 Your data just got a serious AI upgrade — are you ready? Say hello to the Agentic Era with the ...

Feel the Splunk Love: Real Stories from Real Customers

Hello Splunk Community,    What’s the best part of hearing how our customers use Splunk? Easy: the positive ...