Skip to Main Content

Database Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

PL/SQL - DML triggers -- make the complete records available as OLD/NEW values

user7111641Jan 16 2025

Hello All,
I have a suggestion that maybe has already been submitted in some form in the past.

Namely, in DML before/after ROW level triggers, where we can access the pre/post values of each column
by using :OLD.col_name and :NEW.col_name, it would be very convenient to be able to access the entire record.

For any table T, we could have something like :OLD.ROW and :NEW.ROW, where OLD.ROW and NEW.ROW
are defined as RECORD data types containing ALL the columns, in the order they are defined in the table.

The only problem I see here is that, if the table contains invisible columns, then the :OLD.ROW and :NEW.ROW
“lose type compatibility” with T%ROWTYPE, which contains only the visible columns.

Or, as an alternative, :OLD.ROW and :NEW.ROW could be defined as containing only the visible columns,
so that they are fully compatible with T%ROWTYPE.

Thanks a lot for your attention & Best Regards,
Iudith Mentzel

Comments

SiatGesi Feb 14 2025

THE FIRST problem howto wrap I have resolved…

SiatGesi Feb 14 2025

now I'm trying to move the unzipped files (pictures) from db to AS… my real problem… best regards

1 - 2

Post Details

Added on Jan 16 2025
0 comments
46 views