elasticsearch短语匹配

发布时间:2020-05-13 18:38:08 阅读:754次

https://www.cnblogs.com/chenmz1995/p/11446422.html

https://blog.csdn.net/sinat_29581293/article/details/81486761

{

"query":{
    "bool":{
        "must":[
            {
                "match_phrase":{
                    "title":{
                        "query":"版本"                    }
                }
            }
        ],
        "should":[
            {
                "match_phrase":{
                    "title":{
                        "query":"配置"
                    }
                }
            },
            {
                "match_phrase":{
                    "content":{
                        "query":"配置"
                    }
                }
            }
        ],
        "disable_coord":false,
        "adjust_pure_negative":true
    }
},
    "highlight":{
        "fields":{
            "title":{

            },
            "content":{

            }
        }
    }


}

如有问题,可以QQ搜索群1028468525加入群聊,欢迎一起研究技术

支付宝 微信

有疑问联系站长,请联系QQ:QQ咨询

转载请注明:elasticsearch短语匹配 出自老鄢博客 | 欢迎分享