Skip to Main Content

SQL & PL/SQL

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!

Using new and old pseudo columns in dynamic SQL in triggers

user597769Aug 19 2014 — edited Aug 20 2014

Hi,


I need to use the new & old pseudo columns in a dynamic SQL & extract their values. The end user selects the columns of a table that need to be audited & the table contains many columns. Hence, in the after update trigger on the table - my column name is in a variable. So basically i need some means by which i can dereference the variable containing my column's name and use it along with the new & old pseudo record types to get the old value and the new value.


One way of doing this (I thought) is using execute immediate. But this does not work as the ':' means different things in the dynamic SQL world.

many thanks

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 17 2014
Added on Aug 19 2014
5 comments
5,577 views