GET fusion/basicInfo/_search
{
"query": {
"bool": {
"must": {
"match": {
"NAME": {
"query":"阿里巴巴",
"operator": "and"
}
}
},
"should": [
{ "match": {
"NAME": {
"query": "淘宝",
"boost": 3
}
}},
{ "match": {
"NAME": {
"query": "有限公司",
"boost": 2
}
}}
]
}
}
}
可以使用bool查询,在其中添加boost的大小来增加权重