#community-help

Querying Optional Fields with Non-null Values

TLDR Max asked about querying documents where an optional field is not null. Jason shared a prior discussion link and stated there's no direct filter for null values.

Powered by Struct AI

1

1

Mar 23, 2023 (9 months ago)
Max
Photo of md5-ac5d64b63e48fd1a3cf936c3e2221a2c
Max
02:16 PM
Hi ! I would like to query_by a field that is optional. So in the index, the documents where the field=null do not have the field at all. How to query_by where field is not null ?
02:19
Jason
02:19 PM
There’s no filter by null values otherwise directly

1

Max
Photo of md5-ac5d64b63e48fd1a3cf936c3e2221a2c
Max
03:24 PM
Thanks!

1