匯出Oracle中的同義詞

xypincle發表於2017-02-19

  1. --匯出所有的同義詞
  2. SELECT 'CREATE OR REPLACE PUBLIC SYNONYM ' || '"' || SYNONYM_NAME || '"' ||
  3.        ' FOR ' || '"' || TABLE_OWNER || '"' || '.' || '"' || TABLE_NAME || '"' || ';'
  4.   FROM DBA_SYNONYMS A
  5. WHERE A.TABLE_OWNER IN ('ACCT','BLDBANK','COMM','CPR','ECONSTAT','EQUIPMENT','EXAM','INFECT','INPADM','INPBILL','INQUIRE','INSURANCE','LAB',
  6. 'MEDADM','MEDREC','NURSING','ORDADM','OUTPADM','OUTPBILL','OUTPDOCT','PHARMACY','PHYEXAM','SURGERY','TJRIS') ;

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/28878983/viewspace-2133893/,如需轉載,請註明出處,否則將追究法律責任。

相關文章