【发布时间】:2014-06-10 06:56:47
【问题描述】:
在 Oracle Sql Developer 中,我运行 GRANT MyRole TO MyUser; 命令将 MyRole 授予 MyUser,然后运行 REVOKE MyRole FROM MyUser; 命令从 MyUser 撤消 MyRole,但出现错误:
Error starting at line 50 in command:
REVOKE MyRole FROM MyUser
Error report:
SQL Error: ORA-01932: ADMIN option not granted for role 'MyRole'
01932. 00000 - "ADMIN option not granted for role '%s'"
*Cause: The operation requires the admin option on the role.
*Action: Obtain the grant option and re-try.
请告诉我应该怎么做才能从 MyUser 撤消 MyRole。
【问题讨论】:
-
只有数据库所有者才能撤销角色。见这里:docs.oracle.com/javadb/10.6.1.0/ref/rrefsqljrevoke.html
-
@DavidBrabant - 不正确。这只是拥有适当级别的特权的问题。请重新阅读您链接的文档。或者甚至更好地阅读 SQL 参考而不是 Java 文档(见我的回答)
标签: sql oracle privileges