Splunk Search

Why is searching with NOT or != being ignored in search results?

cdupuis123
Path Finder

Anyone else seen this before? I'm building a search, then telling Splunk to NOT or using field!=something and Splunk is straight up ignoring it and showing the field anyway I've tried using quotes, NOT versus != and explicit typing out the value instead of using a wildcard.

Tags (1)
0 Karma

tskinnerivsec
Contributor

If you use NOT, try using parens around the search string you are trying to exclude. I've also seen it make a difference whether you are using a raw search or a datamodel / tstats search. When using !=, make sure to be specifying a field, such as query !="*.arpa". There are plenty of times, I have to monkey around with the order of my syntax, but ultimately, I can get data excluded from search results. Just be careful with your use of wildcards, quotes and make sure that the field names actually exist when using !=

0 Karma

richgalloway
SplunkTrust
SplunkTrust

The last time this happened to me, I had spelled the field name incorrectly.

Please share samples of your data and your failed searches so we figure out what's wrong.

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

Introducing the Splunk Community Dashboard Challenge!

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

Get the T-shirt to Prove You Survived Splunk University Bootcamp

As if Splunk University, in Las Vegas, in-person, with three days of bootcamps and labs weren’t enough, now ...

Wondering How to Build Resiliency in the Cloud?

IT leaders are choosing Splunk Cloud as an ideal cloud transformation platform to drive business resilience,  ...