MongoDB插入查询数据(二), 条件查询
程序员文章站
2024-01-10 23:01:40
...
db.things.find({name:"mongo" }).forEach(printjson);{ "_id" : ObjectId("501c7e5cab2f3c46faf8e68a"), "name" : "mongo" } 相当于 SELECT * FROM things WHERE . 里指定元素的名字 SELECT name FROM things WHERE db.things.find({name:"mongo"}, {name:
> db.things.find({name:"mongo"}).forEach(printjson); { "_id" : ObjectId("501c7e5cab2f3c46faf8e68a"), "name" : "mongo" }
相当于SELECT * FROM things WHERE
下一篇: 判断网赚项目是否为骗子的方法分析