0
我正在嘗試查詢帶有空geo_point字段的文檔的elasticsearch索引。該字段存在,但它是空白的(例如下面)。用於篩選string
字段的查詢不適用於geo_point
字段。Elasticsearch:過濾具有空geo_point值的文檔
文件:
"_source": {
"latitudeLongitude": "",
"pickupLocationZipcode": "",
}
查詢過濾字符串字段的作品,但不geo_point領域:
{
"query": {
"filtered": {
"filter": {
"term": {
"latitudeLongitude": ""
}
}
}
}
}
映射:
"latitudeLongitude": {
"type": "geo_point"
}
"pickupLocationZipcode": {
"index": "not_analyzed",
"type": "string",
"copy_to": [
"pickup_location_zipcode"
]
}