mongoDB第五讲

Count+Distinct+Group 1.Count 请查询persons中美国学生的人数. db.persons.find({country:"USA"}).count() 2.Distinct 请查询出persons中一共有多少个国家分别是什么. db.runCommand({distinct:"persons“, key:"country"}).values 3.Group 语法: db
相关文章
相关标签/搜索