使用Elastic Search 6.4.2。尝试实现突出显示关键字。当我尝试运行以下查询时,出现了不受支持的错误。在此查询中使用突出显示的任何方式。
查询:
{
"query":{
"bool":{
"must":{
"query_string":{
"query":"test"
}
},
"filter":{
"term":{
"college":"engineering"
}
},
"highlight":{
"fields":{
"*":{
}
}
}
}
}
}
错误:
"[bool] query does not support [highlight]"
最佳答案
高亮参数必须与查询处于同一级别,而不是内部。
关于elasticsearch - 在Elastic Search中突出显示搜索到的关键词,并给出一个错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53636927/