0

Elasticsearch documentation says

If the bool query is a filter context or has neither must or filter then at least one of the should queries must match a document for it to match the bool query.

So I can have a bool query with a should clause along with must or filter within a filter context and then still get an exact match. How to do this combination?

I would also be interested in knowing how to do this with Jest client?

Dharman
  • 30,962
  • 25
  • 85
  • 135
Heartin
  • 1
  • 2

1 Answers1

0

In that case you need to add minimum_should_match: 1 if you want that at least one of your should clauses match.

Val
  • 207,596
  • 13
  • 358
  • 360