Splunk Search

search using conditional operators are case sensitive

cpt12tech
Contributor

This search will not work:
index=mail and (scriptName=ACF or scriptName=ACE)

This search will work:
index=mail AND (scriptName=ACF OR scriptName=ACE)

0 Karma

stephanefotso
Motivator

That is true. AND is not and. But i thing here you don't need to use the AND because index=mail (scriptName=ACF OR scriptName=ACE) is the same with index=mail AND (scriptName=ACF OR scriptName=ACE)

Also, when you say index=mail and (scriptName=ACF OR scriptName=ACE), this match all events where index= mail and that events must have the word and and then the sourcetype must be ACF or the scriptNAME must be ACE

But when you say index=mail (scriptName=ACF OR scriptName=ACE), this match all events where the index= mail, and sourcetype= ACF or sriptName=ACF

Thanks

SGF
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,  ...