数据仓库服务 GAUSSDB(DWS)-REVOKE:示例

时间:2024-09-24 15:54:41

示例

撤销joe用户的所有权限:
1
REVOKE ALL PRIVILEGES FROM joe;
撤销指定模式上授予的权限:
1
REVOKE USAGE,CREATE ON SCHEMA tpcds FROM tpcds_manager;

撤销joe用户的CONNECT特权:

1
REVOKE CONNECT ON DATABASE mydatabase FROM joe;

从用户joe撤销角色admins中的成员资格:

1
REVOKE admins FROM joe;

撤销用户joe对视图myView具有的所有特权:

1
REVOKE ALL PRIVILEGES ON myView FROM joe;

撤销针对表customer_t1的public插入特权:

1
REVOKE INSERT ON customer_t1 FROM PUBLIC;

撤销用户joe对模式tpcds的使用权限:

1
REVOKE USAGE ON SCHEMA tpcds FROM joe;

撤销用户joe对tpcds.reason表中r_reason_sk,r_reason_id的查询权限:

1
REVOKE select (r_reason_sk, r_reason_id) ON tpcds.reason FROM joe;

撤销用户joe对函数func_add_sql的执行权限:

1
REVOKE execute ON FUNCTION func_add_sql(integer, integer) FROM joe CASCADE;
support.huaweicloud.com/sqlreference-910-dws/dws_06_0253.html