I want to create autocompletition for facets. For example, you filter
document by value of some field using wildcard query like this:
{
"query": {
"bool": {
"must": [
{
"query_string": {
"query": "foobar* ",
"default_operator": "and",
"analyze_wildcard": true,
"fields": [
"foo_field.analyzed"
]
}
}
]
}
}
}
Autocomplete values are created as terms facet on foo_field.untouched
(not_analyzed field).
If the foo_field is an array and consists of [foobar, bar], autocomplete
facet values are foobar, bar - but i only want to get matching value -
foobar.
I used suggest feature and suggester plugin already, but i need to
constrain the documents with query and filter (for facet using
facet_filter) and also i need to include facet counts, so my only options
is to use facets with facet filter.
Is there any way to create facet on values of document only matching the
given value if the field is an array without using facet script? Can i use
facets on nested attributes or object to achieve this somehow?
Thanks
--
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.
For more options, visit https://groups.google.com/groups/opt_out.