Sample Doc :
{
"id": "K",
"powers": [
{
"label": "a",
"Rating": 7
},
{
"label": "b",
"Rating": 3
},
{
"label": "c",
"Rating": 4
},
{
"label": "d",
"Rating": 5
}
],
"phy": {
"height": 67,
"weight": 150
}
}
For this collection, I want to count how many distinct powers each id has.
I want the result as - ID =K, distinct power label - 4