Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update grant.md #829

Merged
merged 1 commit into from
Nov 14, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

`REVOKE` 语句与 `GRANT` 相关,允许租户删除用户权限。有关 `REVOKE` 的更多信息,请参阅 [REVOKE](revoke.md)。

一般情况下,一个集群默认有一个 *root*,*root* 首先使用 `CREATE ACCOUNT` 创建一个新账户,并定义它的非特权权限,例如它的密码,然后租户使用 `CREATE USER` 创建用户并使用 `GRANT` 对其赋权。`ALTER ACCOUNT` 可用于修改现有租户的非特权特征。`ALTER USER` 用于修改现有用户的权限特征。如需了解 MatrixOne 支持的权限以及不同层级的权限,请参阅 [MatrixOne 权限分类](../../access-control-type.md)。
一般情况下,一个集群默认有一个 *root*,*root* 首先使用 `CREATE ACCOUNT` 创建一个新账户,并定义它的非特权权限,例如它的密码,然后租户使用 `CREATE USER` 创建用户并使用 `GRANT` 对其赋权。`ALTER ACCOUNT` 可用于修改现有租户的非特权特征。`REVOKE` 用于修改现有用户的权限特征。如需了解 MatrixOne 支持的权限以及不同层级的权限,请参阅 [MatrixOne 权限分类](../../access-control-type.md)。

`GRANT` 在成功执行后,得到结果 `Query OK, 0 rows affected`。要查看操作产生的权限,请使用 [SHOW GRANTS](../Other/SHOW-Statements/show-grants.md)

Expand Down Expand Up @@ -51,7 +51,7 @@ priv_level: {

- `GRANT` 不能在同一语句中同时授予权限和角色。

- `ON` 子句区分语句是否授予特权或角色
- `ON` 子句区分语句是否授予权限或角色

+ 使用 `ON`,该语句授予权限。

Expand Down