![](/img/trans.png)
[英]Elasticsearch exists filter how to make an empty string as null value?
[英]ElasticSearch filter query for having null value
我想从 elasic 搜索文档中过滤数据,例如具有空白列表的文档。 我怎么能做到这一点。 假设我想要这个结果。
1) { 姓名:'vipul', 性别:[] }
这是有空白列表
您可以将bool
查询与exists
查询组合,如下所示:
"bool": {
"must_not": [
{
"exists": {
"field": "gender"
}
}
]
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.