查询从单个节点获取具有连字符的多个值 - 弹性搜索

时间:2017-11-08 07:26:28

标签: elasticsearch

到目前为止,查询我试过

{
    "query": {
    "constant_score": {
    "filter": {
    "terms": {
        "website_alias": [
            "chinajianghai.com",
            "perlong.com",
            "kasogroup.com",
            "kndmed.com",
            "medicalequipment-msl.com"
         ]
     }
   }
 }
}
}

我只得到了四个结果" chinajianghai.com"," perlong.com"," kasogroup.com"," kndmed.com&#34 ;除了" medicalequipment-msl.com"。因为最后一个值有连字符。我该如何纠正这个问题?

1 个答案:

答案 0 :(得分:0)

尝试将'website_alias'更改为'website_alias.keyword'?