导入数据后编译所有对象的脚本

发表于:2007-06-22来源:作者:点击数: 标签:

   
  connect user/password@connectstr
  set head off
  set pagesize 0
  set feedback off
  spool temp.sql

  select 'ALTER '||object_type||' '||object_name||' compile;' from user_objects where object_type in ('VIEW','TRIGGER','PROCEDURE','FUNCTION','PACKAGE','PACKAGE BODY');
  spool off
  @temp.sql
  /

原文转自:http://www.ltesting.net