GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Interview Questions  >  Oracle  >  Scenarios
Go To First  |  Previous Question  |  Next Question 
 Scenarios  |  Question 22 of 25    Print  
Very next day on the prodction box It looks some procedres/packages got invlidated. What command I should give to know how many packges are invalidated. If suppose thousands are the packages invalidated then what command I should Issut to get then validated.

  
Total Answers and Comments: 7 Last Update: May 03, 2009     Asked by: agarwalk_2000 
  
 Sponsored Links

 
 Best Rated Answer
Submitted by: Parveeb Ahuja
 
Use dbms_utility.compile_schema procedure to compile all the functions,procedure and packages for a schema.exec dbms_utility.compile_schema('schema_name');

Above answer was rated as good by the following members:
aravindhreturns
March 29, 2006 21:01:10   #1  
Parveeb Ahuja        

RE: Very next day on the prodction box It looks some p...
Use dbms_utility.compile_schema procedure to compile all the functions procedure and packages for a schema.exec dbms_utility.compile_schema('schema_name');
 
Is this answer useful? Yes | NoAnswer is useful 1   Answer is not useful 0Overall Rating: +1    
April 30, 2006 12:07:09   #2  
pandish Member Since: April 2006   Contribution: 7    

RE: Very next day on the prodction box It looks some p...
and use following sql to find the invalid objects.select * from all_objects or dba_objects where status 'INVALID' ;
 
Is this answer useful? Yes | NoAnswer is useful 0   Answer is not useful 2Overall Rating: -2    
July 07, 2006 10:38:51   #3  
Ritesh Singh        

RE: Very next day on the prodction box It looks some p...

select object_name object_type status from dba_objects

where status 'INVALID';

you can run utlrp.sql residing in $ORACLE_HOME/rdbms/admin

and it will try to validate all the objects


 
Is this answer useful? Yes | NoAnswer is useful 1   Answer is not useful 0Overall Rating: +1    
October 03, 2006 04:18:44   #4  
GIGI GEORGE        

RE: Very next day on the prodction box It looks some p...
select 'alter '|| DECODE(object_type 'PACKAGE BODY' 'PACKAGE' object_type)||' '||object_name||' compile;' from user_objects where status<>'VALID' order by object_type try ot this...  then copy and paste on sql prompt..cheersbye
 
Is this answer useful? Yes | NoAnswer is useful 1   Answer is not useful 0Overall Rating: +1    
March 30, 2007 18:49:02   #5  
Chiranjeevi Manne        

RE: Very next day on the prodction box It looks some p...
The best way to check for the number of invalid objects is using the "UTLRP.SQL" which compiles all the objects source code and lists the number of invalid objects. One after getting the number of invalid objects query v$BH table to get the name of all the invalid objects
 
Is this answer useful? Yes | NoAnswer is useful 0   Answer is not useful 1Overall Rating: -1    
April 20, 2009 08:21:05   #6  
samareshp Member Since: April 2009   Contribution: 24    

RE: Very next day on the prodction box It looks some procedres/packages got invlidated. What command I should give to know how many packges are invalidated. If suppose thousands are the packages invalidated then what command I should Issut to get then va
select * from all_objects where object_type 'PACKAGE' and status 'INVALID' ;
 
Is this answer useful? Yes | NoAnswer is useful 0   Answer is not useful 1Overall Rating: -1    
May 02, 2009 15:31:43   #7  
vaddapalli Member Since: May 2009   Contribution: 2    

RE: Very next day on the prodction box It looks some procedres/packages got invlidated. What command I should give to know how many packges are invalidated. If suppose thousands are the packages invalidated then what command I should Issut to get then va

we can use the @?/rdbms/admin/utlrp.sql

The below listed are the scripts that were executed to valid the DBMS_STAT on particular databses.


@?/rdbms/admin/dbmsstat.sql

@?/rdbms/admin/prvtstas.plb

@?/rdbms/admin/prvtstat.plb


 
Is this answer useful? Yes | NoAnswer is useful 0   Answer is not useful 1Overall Rating: -1    


 
Go To Top


 Sponsored Links

 
About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2009 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape