From f483a4eb73808615f8d5d865d6d258940f32f310 Mon Sep 17 00:00:00 2001 From: cooper-lzy <78672629+cooper-lzy@users.noreply.github.com> Date: Wed, 1 Dec 2021 13:45:01 +0800 Subject: [PATCH] add DESCRIBE USER (#952) --- .../1.authentication/2.management-user.md | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/docs-2.0/7.data-security/1.authentication/2.management-user.md b/docs-2.0/7.data-security/1.authentication/2.management-user.md index 4958a9fdb6a..a5bd1e8b72d 100644 --- a/docs-2.0/7.data-security/1.authentication/2.management-user.md +++ b/docs-2.0/7.data-security/1.authentication/2.management-user.md @@ -58,6 +58,28 @@ Users with the **GOD** role or the **ADMIN** role can run `REVOKE ROLE` to revok nebula> REVOKE ROLE USER ON basketballplayer FROM user1; ``` +## DESCRIBE USER + +Users can run `DESCRIBE USER` to list the roles for a specified user. + +* Syntax + + ```ngql + DESCRIBE USER ; + DESC USER ; + ``` + +* Example + + ```ngql + nebula> DESCRIBE USER user1; + +---------+--------------------+ + | role | space | + +---------+--------------------+ + | "ADMIN" | "basketballplayer" | + +---------+--------------------+ + ``` + ## SHOW ROLES Users can run `SHOW ROLES` to list the roles in a graph space.