Splunk Search

How to use IN clause in a search string?

lhumbertosplunk
New Member

Why does the following string work:

url=*string1* OR url=*mystring2*

But, this one does not work?

url in (*mystring1*, *mystring2*)

0 Karma
1 Solution

richgalloway
SplunkTrust
SplunkTrust

Use IN (all caps).

---
If this reply helps you, Karma would be appreciated.

View solution in original post

0 Karma

richgalloway
SplunkTrust
SplunkTrust

Use IN (all caps).

---
If this reply helps you, Karma would be appreciated.
0 Karma

lhumbertosplunk
New Member

Unbelievable! Sucks being a newbie.

It accepted "in" as a reserved word (color change). Never crossed my mind to test "IN". Shame!

0 Karma

lhumbertosplunk
New Member

Unbelievable. It accepted "in" as a reserved word (different color in syntax).

Sucks being a newbie.

Thank you!

0 Karma
Get Updates on the Splunk Community!

Platform Newsletter Highlights | March 2023

 March 2023 | Check out the latest and greatestIntroducing Splunk Edge Processor, simplified data ...

Enterprise Security Content Updates (ESCU) - New Releases

In the last month, the Splunk Threat Research Team (STRT) has had 3 releases of new content via the Enterprise ...

Thought Leaders are Validating Your Hard Work and Training Rigor

As a Splunk enthusiast and member of the Splunk Community, you are one of thousands who recognize the value of ...