mongolab / mongoctl

Manage MongoDB servers and replica sets using JSON configurations!
MIT License
178 stars 25 forks source link

New Database #26

Closed duane701 closed 8 years ago

duane701 commented 8 years ago

How does one initialize a new database with mongoctl from a script?

I would like to create a new database instance on an existing server from a script.

Creating a new database requires using "use dbname", however, if I put "use dbname" in an eval script or direct to the eval option, I receive a syntax error.

duane701 commented 8 years ago

Mongo Newbie:

use <db> is shell helper for db = db.getSiblingDB('<db>')