Closed houzhongjian closed 5 years ago
oh cannot use this method to execute the mongodb shell !!!
The following is the right way
$ mongo 127.0.0.1/demo --authenticationDatabase 'admin' --username 'jiuzhou' --password 'jiuzhou' --quiet --eval="db.user.find().limit(10)";
i want to use mgo run
mongodb shell
!! like db.Query("db.user.find({name:"jack"})") but I don't know which API to use.