VeloDB Cloud
SQL Manual
Statments
Show-Statements
SHOW-GRANTS

SHOW-GRANTS

Name

SHOW GRANTS

Description

This statement is used to view user privileges.

Syntax:

SHOW [ALL] GRANTS [FOR user_identity];

Note:

  1. SHOW ALL GRANTS can view the permissions of all users.
  2. If user_identity is specified, the system will display the privileges of the specified user. And the user_identity must be an existing one created by the CREATE USER command.
  3. If user_identity is not specified, the system will display the privileges of the current user.

Example

  1. View all user privileges

    SHOW ALL GRANTS;
  2. View the privileges of the specified user

    SHOW GRANTS FOR jack@'%';
  3. View the privileges of the current user

    SHOW GRANTS;

Keywords

SHOW, GRANTS

Best Practice