Queries vs. Filters

前端 未结 8 847
太阳男子
太阳男子 2020-11-29 15:20

I can\'t see any description of when I should use a query or a filter or some combination of the two. What is the difference between them? Can anyone please explain?

8条回答
  •  感情败类
    2020-11-29 15:32

    Since version 2 of Elasticsearch, filters and queries have been merged and any query clause can be used as either a filter or a query (depending on the context). As with version 1, filters are cached and should be used if scoring does not matter.

    Source: https://logz.io/blog/elasticsearch-queries/

提交回复
热议问题