Skip to main content

Posts

Showing posts with the label open-database

How to open a new database and a new collection in Mongodb

As contrast to relational databases, mongodb doesn't explicitly open a new database or a collection. User just says to mongodb to use a database no matter it is available currently or not. When a save action is performed, this database is automatically created by mongodb. I will take following actions in mongo shell. Currently, I have following databases in mongodb:  > show dbs local 0.078125GB monitoring 0.203125GB test 0.203125GB