Select to view content in your preferred language

Unique value NULL

2642
2
01-06-2016 08:08 PM
ChrisGordon
New Contributor

When I 'Get Unique Values' for a field in Query Builder one of those values that shows is NULL, yet when I I set that field equal to NULL it tells me 'no records returned'. If no records returned then why does it show NULL as a unique value, and how can I eliminate NULL from the list of unique values? I don't really want it there.

0 Kudos
2 Replies
ChrisSmith7
Honored Contributor

Are you sure you're using the ArcGIS JavaScript API for this and not the query builder in ArcMap? You have this posted in "ArcGIS Server with JavaScript API". Also, when testing for null, it's not "<> null" or "= null", it's "is not null" to exclude and "is null" to include.

0 Kudos
ChrisSmith7
Honored Contributor

Oh, and the reason for this is because null is not a value... you can't compare something that's not a value to another value, hence, why x = null can never be true.

0 Kudos