随笔-314  评论-209  文章-0  trackbacks-0
CREATE OR REPLACE Procedure Create_Synonym Authid Current_User Is
  Sun Varchar2(1000);
  i   Number;
Begin
  For i In (Select Table_Name From Dba_Tables Where Owner = 'NEWWSS') Loop
    Begin
      Sun := i.Table_Name;
      Execute Immediate 'create or replace synonym WSS_' || Sun ||
                        ' for NEWWSS.' || Sun || '@WSS_LINK.US.ORACLE.COM';
    Exception
      When Others Then
        Null;
    End;
  End Loop;
End Create_Synonym;
posted on 2007-10-24 11:05 xzc 阅读(2192) 评论(0)  编辑  收藏 所属分类: Oracle

只有注册用户登录后才能发表评论。


网站导航: