摘要:
db.getCollections('students').update({},{$set:{}},{upsert:false,multi:false}) 更新单行,upsert为true时,更新不存在的数据,即为添加数据 db.getCollections('students').update({ 阅读全文
posted @ 2018-05-15 23:36
江山一族
阅读(159)
评论(0)
推荐(0)
摘要:
db.getClloection('user').find().sort({'age':-1}).pretty() 2.自然排序,也就是插入的先后顺序 db.getClloection('user').find().sort({'$natural':-1}) 阅读全文
posted @ 2018-05-15 08:30
江山一族
阅读(144)
评论(0)
推荐(0)

浙公网安备 33010602011771号