You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would love to see an option of a nested query where instead of returning parent docs where any nested doc matches a nested query, there could be an option to return only parent docs when some minimum number of nested docs matched. Similar to the way we set up minimum_should_match. In my particular case I would want to only return parent docs where ALL the nested docs match a specific query.
Example:
PUT test
{
"mappings": {
"_doc": {
"properties": {
"comments": {
"type": "nested"
}
}
}
}
}
Describe the feature:
I would love to see an option of a nested query where instead of returning parent docs where any nested doc matches a nested query, there could be an option to return only parent docs when some minimum number of nested docs matched. Similar to the way we set up minimum_should_match. In my particular case I would want to only return parent docs where ALL the nested docs match a specific query.
Example:
Then, in order to only match doc 2, where all the nested docs match the query:
Perhaps there is already some way of doing this that I don't know about?
The text was updated successfully, but these errors were encountered: