今天给一个普通用户查询v$database视图的权限,报ORA-02030: can only select from fixed tables/views错误。
SQL> grant select on v$database to jtitsm;
grant select on v$database to jtitsm
*
ERROR at line 1:
ORA-02030: can only select from fixed tables/views
处理:
我们可以直接把v_$database 视图的权限赋给用户,然后该用户就可以查询v$database视图了。
SQL> grant select on v_$database to jtitsm;
Grant succeeded.
登录jtitsm用户检查是否可以查询。
SQL> show user;
USER is "JTITSM"
SQL> select DBID,name from v$database;
DBID NAME
---------- ---------------------------
363222396 ABCBI
jtitsm用户可以查询v$database视图了。
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/11590946/viewspace-1063747/
,如需转载,请注明出处,否则将追究法律责任。