Use the DROP USER statement to drop a user.
Prerequisites
You must have the global CREATE USER privilege. For information about how to view your privileges, see View user privileges. If you do not have the global CREATE USER privilege, contact the administrator to obtain the privilege. For information about how to grant privileges to a user, see Modify user privileges.
Limitations
The DELETE statement cannot be used to delete privileges from the mysql.user table.
Procedure
Log on to a MySQL tenant of the cluster.
Execute the following statement to drop one or more users:
DROP USER user_name [, user_name...];where
user_namespecifies the username of the user to be dropped. When dropping multiple users at the same time, separate the usernames with commas (,).After a user is successfully dropped, the database objects created by the user will not be dropped, but all privileges of the user will be revoked.
Here is an example:
obclient> DROP USER sqluser02; Query OK, 0 rows affected
References
For more information about the DROP USER statement, see DROP USER.