Here are the most commonly used Mongo Shell commands with example usage.
[1] Databases are created on the fly and will actually be created when you insert something into it.
[2] Collections are created on the fly when you insert first document into it.
Thanks for this post, It's short and very helpful
Lolita Love | April 29, 2020 7:44 AM |I think the same, very helpful.
brian | July 13, 2019 2:45 AM | @89rtE | October 2, 2017 3:30 PM |Lots of HW, GZ. THX.
Shy Tamir | December 29, 2016 10:46 AM |You might want to add this little gem for validation of data files. I use it on our restored daily backup to verify it's usable: db.getSiblingDB("admin").runCommand("listDatabases").databases.forEach(function(d)