db.stu.aggregate([ {$match:{age:{$gt:20}}} ])
db.stu.aggregate([ {$match:{age:{$gt:20}}}, {$group:{_id:'$gender',counter:{$sum:1}}} ])