Multiply dis_max query score


(Amir Peres) #1

Hello,
Until now I used multi_match query and multiply the regular score (not the ngram) by 3:

GET index/type
{
   "query": {
      "bool": {
         "must": [
            {
              "multi_match": {
                 "query": "amir",
                 "fields": ["sometext.value^3","sometext.value.ngram"]
              }
           }
        ]
     }
  }
}

As you can see I multiply the regular value score (not the ngram) by 3.
Now I am trying to do the same thing with the dismax query but it is not working:

GET index/type
{
   "query": {
      "dis_max": {
         "queries": [
            {
              "match": {
                 "sometext.value^3": "amir"
              }
           },
           {
             "match": {
                "sometext.value.ngram": "amir"
             }
          }
        ]
     }
  }
}

What is the solution?
Thanks ahead.


(system) #2

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.