Reverse Nested Aggregation Sort

Hi all,

I am wondering whether it is possible to sort a reverse nested aggregation
by the document count of the joined root / document the nested object
belongs to. The counts of the nested objects and the root document counts
can be off.

I was hoping it is possible to do this in ES and not by double traversing
the array to get the sort order by document count right.

Thanks in advance!


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
To view this discussion on the web visit
For more options, visit