Dashboards & Visualizations

How to use lookup table in where in condition?

splunkuser320
Path Finder

I need to create a query where I need to populate a column's values from a lookup table as a default value.  Basically, replace all All in the below value with the values of the column. 

index = "XXX"  log_group IN("All")
| stats sum(event)

Thanks 

Labels (1)
Tags (2)
0 Karma

richgalloway
SplunkTrust
SplunkTrust

This is more of a search question than a dashboard question.

You can use inputlookup in a subsearch to get a list of all column values from a lookup table.

index = "XXX"  [ | inputlookup mylookup.csv | fields log_group | format ]
| stats sum(event)

 

---
If this reply helps you, Karma would be appreciated.
0 Karma
Get Updates on the Splunk Community!

Splunk Mobile: Your Brand-New Home Screen

Meet Your New Mobile Hub  Hello Splunk Community!  Staying connected to your data—no matter where you are—is ...

Introducing Value Insights (Beta): Understand the Business Impact your organization ...

Real progress on your strategic priorities starts with knowing the business outcomes your teams are delivering ...

Enterprise Security (ES) Essentials 8.3 is Now GA — Smarter Detections, Faster ...

As of today, Enterprise Security (ES) Essentials 8.3 is now generally available, helping SOC teams simplify ...