Aggregation on terms with Nested Property

i have below json
attrib is nested property
{

attrib{
color:blue,
categoryId: 1
},
attrib{
color:red,
categoryid: 2}
}
When querying around categoryId : 1 or 2 and get correct result
but while Aggregating on term, I want it to be restricted on categoryId.
How to do that. I tried Nested Aggregation with filter but no luck there.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.