- Reference >
- mongo Shell Methods >
- Database Methods >
- db.dropDatabase()
db.dropDatabase()¶
On this page
Behavior¶
The db.dropDatabase() wraps the dropDatabase command.
Warning
This command obtains a global write lock and will block other operations until it has completed.
Changed in version 2.6: This command does not delete the users associated with the current database. To drop the associated users, run the dropAllUsersFromDatabase command in the database you are deleting.
Thank you for your feedback!
We're sorry! You can Report a Problem to help us improve this page.