`
ry.china
  • 浏览: 137521 次
  • 性别: Icon_minigender_1
  • 来自: 重庆
社区版块
存档分类
最新评论

oracle同义词的使用

 
阅读更多

oracle 下不同用户之间表访问时会碰到一些权限问题,这时候就要用到同义词进行处理了

 

 

同一数据库 
两个不同用户 user1 user2

user1里面有一张表 table1 

在user2里面创建synonym
create synonym sy1 for user1.table1;
是没有问题,
并且
select * from sy1;
也是可以取到数据的.
只不过如果想在存储过程里面使用sy1.
则需要
grant select on table1 to user2;

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics