Learn the "why" behind slow queries and how to fix them in our 2-Part Webinar.
Register now >
Docs Menu
Docs Home
/ /
User Management Methods

db.removeUser()

Deprecated since version 2.6: Use db.dropUser() instead of db.removeUser()

db.removeUser(username)

Removes the specified username from the database.

The db.removeUser() method has the following parameter:

Parameter
Type
Description

username

string

The database username.

Back

db.grantRolesToUser()

On this page