My Oracle Support Banner

Problem With Compound Triggers Losing Local Values When Executing A Merge Statement. (Doc ID 1393441.1)

Last updated on FEBRUARY 11, 2019

Applies to:

PL/SQL - Version 11.2.0.2 and later
Information in this document applies to any platform.

Symptoms


The value of a variable initialized in a compound trigger "BEFORE STATEMENT" is nullified prior to executing the subsequent statement ("BEFORE ROW") when a MERGE sql statement is executed.

The following sample illustrates the issue.

This is the table to be used.


The ORA-01400 occurs because of the "Not Null" constraint.  Since TS is nullified, the insert fails.

Cause

To view full details, sign in with your My Oracle Support account.

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


In this Document
Symptoms
Cause
Solution
References


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.