Mongo: show dbs doesn't show the test db. Why?

前端 未结 1 795
深忆病人
深忆病人 2021-01-17 17:03

When I first type mongo, I see \"connecting to : test\". However, when I type show dbs, it does not show me the test db. I can still s

相关标签:
1条回答
  • 2021-01-17 17:47

    If you type db you will see that you are on database named test, but it won't be shown in list, that happens because test db doesn't contain any document it is empty. You need to create at least one document in test database if you want it to be shown in list after typing show dbs

    0 讨论(0)
提交回复
热议问题