How to See the New Source Code When Using AFTER DDL Trigger? (Doc ID 966537.1)

Last updated on JULY 05, 2017

Applies to:

PL/SQL - Version: 10.2.0.4 - Release: 10.2
Information in this document applies to any platform.

Goal

When using an AFTER DDL trigger then it's not possible to see the source of the renewed code from DBMS_METADATA.GET_DDL after creation. The AFTER DDL trigger fires before the commit of the current DDL statement. The trigger is executed in the transaction of the triggering event. At the time triggers are executed, the dictionary changes have not been commited yet.

Therefore the commit is to execute within a procedure called by a job.
The trigger needs to execute autonomously.

Solution

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms