Filter For Field = Null


(timscott) #1

What's the expected behavior of the MissingFilter when applied to a
(non-analyzed) field is present but with a null value? I am finding
that documents with null values are returned (missing filter not
applied). I tried instead to use the TermFilter with a null value,
but ES choked on that.

How can I filter for a certain non analyzed field = null? I had
solved this before with a wildcard query, but it's much better for me
to use a filter if I can. Thanks.


(Shay Banon) #2

Can you gist a curl recreation where the missing filter is not working?
On Wednesday, March 2, 2011 at 4:45 AM, Tim Scott wrote:

What's the expected behavior of the MissingFilter when applied to a
(non-analyzed) field is present but with a null value? I am finding
that documents with null values are returned (missing filter not
applied). I tried instead to use the TermFilter with a null value,
but ES choked on that.

How can I filter for a certain non analyzed field = null? I had
solved this before with a wildcard query, but it's much better for me
to use a filter if I can. Thanks.


(timscott) #3

My mistake. The data was not what I thought it was. However, in the
same query I am having trouble with the prefix filter. I will open a
new topic with that question and create a gist for it.

On Mar 1, 9:15 pm, Shay Banon shay.ba...@elasticsearch.com wrote:

Can you gist a curl recreation where the missing filter is not working?

On Wednesday, March 2, 2011 at 4:45 AM, Tim Scott wrote:

What's the expected behavior of the MissingFilter when applied to a
(non-analyzed) field is present but with a null value? I am finding
that documents with null values are returned (missing filter not
applied). I tried instead to use the TermFilter with a null value,
but ES choked on that.

How can I filter for a certain non analyzed field = null? I had
solved this before with a wildcard query, but it's much better for me
to use a filter if I can. Thanks.


(system) #4