Autocomplete within multiple fields

Hi,

I would like to get an autocomplete within multiple fields and get the
results sorted within all these fields. Now I can do an autocomplete within
multiple fields but they come unsorted for each one of my searches :

POST /myindex/_suggest

{
"complete1" : {
"text" : "auc",
"completion" : {
"field" : "[article]title(autocomplete)"
}
},
"complete2" : {
"text" : "auc",
"completion" : {
"field" : "[brand]title(autocomplete)"
}
}
}

result =

  • complete1 => hits
  • complete2 => other hits

I would like the results to be sorted. I would like to query something like
:

POST /myindex/_suggest

{
"complete1and2" : {
"text" : "auc",
"completion" : {
"fields" : [ "[article]title(autocomplete)",
"[brand]title(autocomplete)"]
}
}
}

Thank you
Julien

--
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 elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/fc571458-e069-404e-a20b-c135c9b82a0f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.