Note that procedure "DBMS_UTILITY.COMPILE_SCHEMA" compiles only one given/input schema at a time, see description of it below.
But is there possibility for lazy people to compile all schemas? I don't see such procedure. Do i really have to give all the 20 schema names myself, and compile them one-by-one?
COMPILE_SCHEMA Procedure
This procedure compiles all procedures, functions, packages, and triggers in the specified schema.
Syntax
DBMS_UTILITY.COMPILE_SCHEMA (
schema VARCHAR2,
compile_all BOOLEAN DEFAULT TRUE,
reuse_settings BOOLEAN DEFAULT FALSE);
http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14258/d_util.htm#i1002332
(Oracle 10g, Linux OS)
So is this the only solution:
/*
select q'(dbms_utility.compile_schema(schema=>')' || username || q'(');)' from dba_users
*/
BEGIN
Dbms_Utility.Compile_Schema(SCHEMA => 'PUBLIC'); --copy paste others here
END;
Edited by: CharlesRoos on 15.12.2010 17:59