Database
- To show all databases
show dbs;
- To use database
use <database_name>;
- To delete database
db.dropDatabase();
Note: If you don't create collection after switching to new database, then that database won't show if execute show dbs;
show dbs;
use <database_name>;
db.dropDatabase();
Note: If you don't create collection after switching to new database, then that database won't show if execute show dbs;