Last Updated: February 25, 2016
·
806
· ivolimmen

Generate SQL code to compile invalid objects

select 'ALTER ' || OBJECT_TYPE || ' ' || OBJECT_NAME || ' COMPILE;'
from user_objects where status = 'INVALID';

Works without DBA rights but requires ALTER privileges.