Splunk Search

How can I create a lookup where if the user is not found, the result should be NULL?

dlcrooks
Explorer

When searching a lookup and the user is not found then I need the result to be NULL.

Any ideas?

0 Karma

martin_mueller
SplunkTrust
SplunkTrust

You can specify a default value in case there's no match in your lookup definition.

0 Karma

martin_mueller
SplunkTrust
SplunkTrust

The lookup command will use your settings from the lookup defintion:

  • in the lookup definition, set minimum matches to 1 or greater
  • in the lookup definition, set the default matches to whatever string you like
  • use ... | lookup your_lookup_definition your_input_field OUTPUT your_output_fields or whatever
0 Karma

dlcrooks
Explorer

How do I with the command?

0 Karma
Get Updates on the Splunk Community!

AppDynamics Summer Webinars

This summer, our mighty AppDynamics team is cooking up some delicious content on YouTube Live to satiate your ...

SOCin’ it to you at Splunk University

Splunk University is expanding its instructor-led learning portfolio with dedicated Security tracks at .conf25 ...

Credit Card Data Protection & PCI Compliance with Splunk Edge Processor

Organizations handling credit card transactions know that PCI DSS compliance is both critical and complex. The ...