1

Instead of multiple fields to match, I want to give a boosted score. It's part of a bigger query, so unfortunately I cannot avoid having to boost this part of the query.

I tried:

   "terms": {
            "some.keyword": ["a12c", "b12c"],
            "boost": 10
   }

and:

   "terms": {
       "some.keyword": {
           "values": ["a12c", "b12c"], 
           "boost": 10
       } 
   } 

but both do not work.

Dan Mašek
  • 17,852
  • 6
  • 57
  • 85
PascalVKooten
  • 20,643
  • 17
  • 103
  • 160
  • `boost` for `terms` should work. If it seems it doesn't, then your other parts of the "bigger query" do something to the score. – Andrei Stefan May 17 '17 at 14:57
  • @AndreiStefan In the documentation it doesn't state it has an effect. Also, I specifically tested it by seeing no difference in "max_score" given any boost value. – PascalVKooten May 17 '17 at 18:14
  • Is this question really about [Boost C++ Libraries](http://stackoverflow.com/tags/boost/info) as the tag would suggest? Please, next time take the moment to read the tag description before you use the tag (it even shows up as you type the tags). (Fixed) – Dan Mašek May 17 '17 at 21:13

0 Answers0