Forum Discussion
pmancevski
3 years agoNew Contributor III
Hi,
Probably there is simpler solution, but at the moment i can think only this:
Replace previous expression with this:
$group.map((value, index) => value.extend({“sum” : parseInt(value.sum) + ((index + 1) * 10)}))
We are extending the object with same field, because previously we had that field name, it will be only overwritten.
Thanks,
Pero M.
- pradeepkumar3 years agoNew Contributor II
Generally we can use sort snap following unique snap to deal with duplicate data but you need at least one unique data to work with, Need more information on your case to help.