SHOW-GRANTS
Name
SHOW GRANTS
Description
This statement is used to view user permissions.
grammar:
1. SHOW [ALL] GRANTS [FOR user_identity];
illustrate:
- SHOW ALL GRANTS can view the permissions of all users.
- If user_identity is specified, view the permissions of the specified user. And the user_identity must be created by the CREATE USER command.
- If user_identity is not specified, view the permissions of the current user.
Example
- View all user permission information
1. SHOW ALL GRANTS;
2. View the permissions of the specified user
1. SHOW GRANTS FOR jack@'%';
3. View the permissions of the current user
1. SHOW GRANTS;
Keywords
1. SHOW, GRANTS
