美文网首页
ElasticSearch中analyzer和search_an

ElasticSearch中analyzer和search_an

作者: 程序员小白成长记 | 来源:发表于2020-11-11 01:05 被阅读0次

Usually, the same analyzer should be applied at index time and at search time, to ensure that the terms in the query are in the same format as the terms in the inverted index.
Sometimes, though, it can make sense to use a different analyzer at search time, such as when using the edge_ngram tokenizer for autocomplete.
By default, queries will use the analyzer defined in the field mapping, but this can be overridden with the search_analyzer setting:

参考

【1】Elasticsearch中analyzer和search_analyzer的区别
【2】elasticsearch reference: search-analyzer

相关文章

网友评论

      本文标题:ElasticSearch中analyzer和search_an

      本文链接:https://www.haomeiwen.com/subject/lswsbktx.html