oracle如何创建只读用户只读另一用户的表

前端之家收集整理的这篇文章主要介绍了oracle如何创建只读用户只读另一用户的表前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

标红位置改为自己相应的,该例子为创建 READUSER只读USER的表

CREATE USER READUSER IDENTIFIED BY 123;

GRANT CONNECT TO READUSER;


执行如下命令

select 'grant select on '||owner||'.'||object_name||' to USER;'
from dba_objects
where owner ='READUSER'
and object_type='TABLE';


会有如下结果,复制 如下7(n)行执行即可

'GRANTSELECTON'||OWNER||'.'||OBJECT_NAME||'TOREADUSER;' -------------------------------------------------------------------------------- grant select on USER.VISIT_SYSTEM_INFO to READUSER; grant select on USER.VISIT_TIME_DIC to READUSER; grant select on USER.VISIT_TOTAL to READUSER; grant select on USER.VISIT_TOTAL_CHANNEL to READUSER; grant select on USER.VISIT_TOTAL_NEWS to READUSER; grant select on USER.WORDS_HOT_CATEGORY to READUSER; grant select on USER.WORDS_SENSITIVE_CATEGORY to READUSER; 7 rows selected.

原文链接:https://www.f2er.com/oracle/213915.html

猜你在找的Oracle相关文章