hi there,
I am searching ES to find empty string field using "must_not" and exists as follows, but it returns "0" hits. After I change the query to "must" and exists I am getting all hits where the filed having empty value as follows. Any help!
{
"query": {
"bool": {
"must": [
{
"exists": {
"field": "audoc.author_name.preferred_name.preferred_first"
}
}
]
}
}
}
result looks as follows:
"preferred_name" : {
"preferred_first" : "",
"preferred_ini" : "",
"preferred_last" : ""
}