WARNING: The 2.x versions of Elasticsearch have passed their EOL dates. If you are running a 2.x version, we strongly advise you to upgrade.
This documentation is no longer maintained and may be removed. For the latest information, see the current Elasticsearch documentation.
Children Aggregation
edit
IMPORTANT: This documentation is no longer updated. Refer to Elastic's version policy and the latest documentation.
Children Aggregation
editParent-child supports a
children aggregation as a direct analog to the nested aggregation discussed in
Nested Aggregations. A parent aggregation (the equivalent of
reverse_nested) is not supported.
This example demonstrates how we could determine the favorite hobbies of our employees by country: