Splunk Search

How to query two nullable nested fields are not equal? [newbie question]

roliu
New Member

Hi, 

I have a dataset like below

 

 

[
  {classificationA: null, classificationB: null},
  {classificationA: {name: 'Education'}, classificationB: {name: 'Education'}},
  {classificationA: {name: 'IT'}, classificationB: {name: 'IT'}}
} 

 

 

My aim is to find all the rows whose classificationA is not equals to classificationB. So given the above dataset, it should return zero rows.

I thought it should be:

 

 

 | where classficationA != classficationB

 

 

But it is not working.  Anyone can help? Thank you!

Labels (2)
0 Karma

bowesmana
SplunkTrust
SplunkTrust

Is that your 'raw' data - it is not valid JSON. Is that a single event or 3 events?

Please share the raw data - if it's 3 classifications inside a single event, then please paste an example of the true _raw element of the value of a field that's extracted

 

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!

Take Action Automatically on Splunk Alerts with Red Hat Ansible Automation Platform

 Are you ready to revolutionize your IT operations? As digital transformation accelerates, the demand for ...

Calling All Security Pros: Ready to Race Through Boston?

Hey Splunkers, .conf25 is heading to Boston and we’re kicking things off with something bold, competitive, and ...

Beyond Detection: How Splunk and Cisco Integrated Security Platforms Transform ...

Financial services organizations face an impossible equation: maintain 99.9% uptime for mission-critical ...