Using Role Management Commands
This section describes how to use basic syntax and SQL statements to manage roles.
- Creating a roleCREATE Role role_name;
role_name: name of the role to be created
- Granting permissions to a role
- Grant the permissions on a specified database table.GRANT LOAD_PRIV ON ctl1.db1.* TO ROLE 'my_role';
- Grant the permission to use specified resources.GRANT USAGE_PRIV ON RESOURCE 'spark_resource' TO ROLE 'my_role';
- Grant the permissions on a specified database table.
- Deleting a roleDROP ROLE role1;
- Query the permissions and roles of a user.SHOW GRANTS;
Parent topic: Doris Role Management