Splunk Search

How do you compare a field in a search table with a lookup table field?

kdelvillar
Engager

I have a search that produces a table that contains a field called "http_referer", and I want to compare this field against a field called "TargetURL" that's in my inputlookup redirect-url.csv result. If there's a match I would like it to display all the matches.

Tags (1)
0 Karma
1 Solution

kamlesh_vaghela
SplunkTrust
SplunkTrust

@kdelvillar

Have you tried lookup command? I'm not able to understand all the matches with!!!??

Can you please try below search?

YOUR_TABLE_SEARCH | lookup redirect-url.csv TargetURL as http_referer OUTPUTNEW TargetURL as myTargetURL | where isnotnull(myTargetURL)

https://docs.splunk.com/Documentation/Splunk/7.2.0/SearchReference/Lookup

View solution in original post

kamlesh_vaghela
SplunkTrust
SplunkTrust

@kdelvillar

Have you tried lookup command? I'm not able to understand all the matches with!!!??

Can you please try below search?

YOUR_TABLE_SEARCH | lookup redirect-url.csv TargetURL as http_referer OUTPUTNEW TargetURL as myTargetURL | where isnotnull(myTargetURL)

https://docs.splunk.com/Documentation/Splunk/7.2.0/SearchReference/Lookup

kdelvillar
Engager

This worked thank you!

0 Karma

kamlesh_vaghela
SplunkTrust
SplunkTrust

@kdelvillar

Glad to help you. Can you please accept the answer and upvote comment to help the community?

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Community Content Calendar, September edition

Welcome to another insightful post from our Community Content Calendar! We're thrilled to continue bringing ...

Splunkbase Unveils New App Listing Management Public Preview

Splunkbase Unveils New App Listing Management Public PreviewWe're thrilled to announce the public preview of ...

Leveraging Automated Threat Analysis Across the Splunk Ecosystem

Are you leveraging automation to its fullest potential in your threat detection strategy?Our upcoming Security ...