Details
-
Bug
-
Resolution: Done
-
Major - P3
-
None
-
None
-
Operating System = Windows 8.1 32 bit (Virtual Box)
MongoDB version = 3.2.3
*Location*: https://docs.mongodb.org/manual/reference/mongo-shell/
*User-Agent*: Mozilla/5.0 (Windows NT 6.3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.87 Safari/537.36
*Referrer*: https://docs.mongodb.org/manual/search/?query=show%20dbs
*Screen Resolution*: 1366 x 743
*repo*: docs
*source*: reference/mongo-shell
Operating System = Windows 8.1 32 bit (Virtual Box) MongoDB version = 3.2.3 *Location*: https://docs.mongodb.org/manual/reference/mongo-shell/ *User-Agent*: Mozilla/5.0 (Windows NT 6.3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.87 Safari/537.36 *Referrer*: https://docs.mongodb.org/manual/search/?query=show%20dbs *Screen Resolution*: 1366 x 743 *repo*: docs *source*: reference/mongo-shell
Description
I am new to mongodb currently I'm learning from docs and tutorials available online, I need a clarification in certain Mongodb 'show dbs' command. I'm pretty sure that it would list all the databases that we've created.
but there is a slight problem I'm facing with that command
1. I've created a db using the following command
use mytestdb
2. Then I tried to view the current db using command
db
It shown my database name mytestdb
3. finally when I'm trying to see the list of available databases i've created using
show dbs
but still the list didn't consist of my recently created database "mytestdb"
I tried several time but the result is same, I searched about this similar problem in the internet I got two solutions which worked for me
1. Restart mongo client
2. Repair the db using db.repairDatabase() command
Though it worked fine I just need to know why its not refreshing in the real time, is it a feature or a bug, if its a feature I just need to know why and if I am not doing something right please educate me. I'm so much fascinated to learn mongodb completely.
Thank you so much in advance