Splunk Search

how can I search not IN as I was working on a solution building for not including multiple parameters.

Santoshku10
New Member

..........NOT
[search logLevel IN (DEBUG,INFO)]........... it is not giving desired results.

 

how can I search not IN as I was working on a solution building for not including multiple parameters.

Labels (1)
0 Karma

richgalloway
SplunkTrust
SplunkTrust

What are the desired results?

When using subsearches, it helps to start with the subsearch by itself.  Run the subsearch with the | format command added to see what the subsearch will return to the main search.  That returned string must be proper SPL and make sense in your environment (fields must exist, etc.).

In the example shown, search logLevel IN (DEBUG,INFO) will return all events from the user's default indexes that contain a logLevel field with a value of "DEBUG" or "INFO".  

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

Enter the Splunk Community Dashboard Challenge for Your Chance to Win!

The Splunk Community Dashboard Challenge is underway! This is your chance to showcase your skills in creating ...

.conf24 | Session Scheduler is Live!!

.conf24 is happening June 11 - 14 in Las Vegas, and we are thrilled to announce that the conference catalog ...

Introducing the Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...