Splunk Search

How to return value without match in lookup without using lookup advanced options

katzr
Path Finder

Hello,

I want to return the all of the location values in my data even if there is no match to the location in the lookup. I created a lookup table and used the advanced options to specify a default match, but for some reason I am having permission issues with my lookup table which I believe is a splunk bug.

So is there any other way to return all of my values from my data without using the default advanced options. Below is an example of my query. I want to return all of the locations even if not found in my lookup. If you would like to help me with the splunk error with my lookup table also- I can explain the problem more in detail. Thanks for the help!

    index=A | lookup TableName location | search region=*  location=*  country=*
0 Karma

woodcock
Esteemed Legend

Bypass the whole matter by specifying your default manually with |eval location="Unknown" | eval country="Unknown" before you call the lookup. Any match will overwrite the value, any miss will retain it.

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!

A Four-Part Event Series: Full Stack Observability For the AI Era

As AI reshapes applications, infrastructure, and the way teams operate, the traditional boundaries of ...

SOC4Kafka - New Kafka Connector Powered by OpenTelemetry

The new SOC4Kafka connector, built on OpenTelemetry, enables the collection of Kafka messages and forwards ...

Event Series: Level up your SOC: Advancing with Splunk Enterprise Security

AI has fundamentally raised the stakes for security operations, and this three-part series is your guide to ...