(â ) Role management
CREATE ROLE my\_role
Create a role.
CREATE ROLE my_second_role IF NOT EXISTS AS COPY OF my_role
Create a role named my_second_role, unless it already exists, as a copy of the existing my_role.
RENAME ROLE my\_second\_role TO my_other_role
Rename a role named my_second_role to my_other_role.
GRANT ROLE my\_role, my_other_role TO alice
Assign roles to a user.
REVOKE ROLE my\_other\_role FROM alice
Remove a specified role from a user.
SHOW ROLES
List all roles in the system.
SHOW ROLES
YIELD role
WHERE role CONTAINS 'my'
List roles, filtered by the name of the role and further refined by whether the name contains 'my'.
SHOW POPULATED ROLES WITH USERS
List all roles that are assigned to at least one user in the system, and the users assigned to those roles.
DROP ROLE my\_role
Delete a role.
Comments