I need to create a user for my database in mongodb, but it seems that I can\'t get it to work.
I have installed mongoDb v3.0.5 on my windows 7 machine. according to this
When you "use admin", your new user is created in database "admin".
use admin db.createUser( { user: "myUser", pwd: "123456", roles: [ { role: "readWrite", db: "exampleDb" } ] } )
So your connection string must be as:
var connString = "mongodb://myUser:123456@127.0.0.1:27017/admin";