i have solved it in that way...

GET /my_index/my_type1,my_type2/_search
{
  "query": {
    "function_score": {
      "query": {
        "match": {
          "value.autocomplete": "lorem ipsum"
        }
      },
      "functions": [
        {
          "script_score": {
            "lang": "groovy", 
            "script": "doc['_type'].value == 'my_type2' ? _score * 2 : 
_score"
          }
        }
      ]
    }
  }
}

cheers

-- 
You received this message because you are subscribed to the Google Groups 
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/b56befbd-69a7-47b8-9918-29cdcaa6a062%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to