Title: RE: RECOMPILE INVALID OBJECTS

>  from dba_objects A, sys.order_object_by_dependency B


Doesn't work under 8.1.6,  there is not
such view as  'sys.order_object_by_dependency',
however,
you can replace this with an inline view of

from
    dba_objects a,
       (select max(level) dlevel, object_id from public_dependency
       connect by object_id = prior referenced_object_id
       group by object_id) b

----
Matt Adams - GE Appliances - [EMAIL PROTECTED]
The thrill is gone -  B. B. King
If the thrill is gone, then it's time to take it back. -  Meatloaf

> -----Original Message-----
> From: Jamadagni, Rajendra [mailto:[EMAIL PROTECTED]]
> Sent: Monday, December 17, 2001 1:58 PM
> To: Multiple recipients of list ORACLE-L
> Subject: RE: RECOMPILE INVALID OBJECTS
>
>
> --------------------   start ------------------------------
> set heading off
> set pagesize 0
> set linesize 79
> set verify off
> set echo off
> spool recomp_all.tmp
> select decode( OBJECT_TYPE, 'PACKAGE BODY',
>     'alter package ' || OWNER||'.'||OBJECT_NAME || ' compile body;',
>     'alter ' || OBJECT_TYPE || ' ' || OWNER||'.'||OBJECT_NAME
> || ' compile;'
> )
> from dba_objects A, sys.order_object_by_dependency B
> where A.OBJECT_ID = B.OBJECT_ID(+) and
>      STATUS = 'INVALID' and
>  OBJECT_TYPE in ( 'PACKAGE BODY', 'PACKAGE', 'FUNCTION', 'PROCEDURE',
>                   'TRIGGER', 'VIEW' )
> order by DLEVEL DESC, OBJECT_TYPE, OBJECT_NAME;
> spool off
>
> @recomp_all.tmp
> ---------------- end ----------------------------
> Raj
> ______________________________________________________
> Rajendra Jamadagni            MIS, ESPN Inc.
> Rajendra dot Jamadagni at ESPN dot com
> Any opinion expressed here is personal and doesn't reflect
> that of ESPN Inc.
>
> QOTD: Any clod can have facts, but having an opinion is an art!
>

Reply via email to