Mongodb – how does mongo db group by using aggregate?
how attribute does mongodb uses to group by ? do they use only the "_id" or the ( "_id" AND "Total departments") I am slightly confused because "_id" and "Total Departments" are in the same curly bracket $group db.department.aggregate([ {…