当我想从弹性搜索中获取数据时出现解析异常。我的文档看起来像这样
{
"_index": "some name",
"_type": "row",
"_id": "665",
"_score": 6.3700795,
"_source": {
"dateOfClaim": 1215986400000,
"employer": {
"username": null,
"password": null,
"name": "customer",
"customerNumber": "some number",
"dosierNumbers": null
},
"recipient": {
"username": null,
"password": null,
"name": "some name",
"taxNumber": "some number"
},
"claim": 402401,
"dosierNumber": "",
"worthWayTaxes": "",
"good": {
"brutoWeight": 25,
"nettoWeight": 25050,
"coll": 25000,
"taxWorth": "58830.67",
"eori": ""
},
"poDValues": "YES",
"correctedTaxNumber": null,
"note": null
}
},
我的查询看起来像这样
POST /customs/_search
{
"nested" : {
"path" : "employer",
"score_mode" : "none",
"query" : {
"match": {
"employer.name" : "customer"
}
}
}
}
我想获取 poDValue 为 NO 的特定雇主的所有文件。但是我的查询已经给了我一个解析异常(所有分片在阶段失败:[查询]),即使没有说 poDValue 应该是 NO。