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!

changing new values in trigger

Rob JonesMay 30 2013 — edited May 30 2013
Hi,
Using Oracle 11g R2.

When inserting records into a table, I'd like to replace a certain character with a space character inside of a "AFTER DELETE OR INSERT OR UPDATE" type of trigger. However, when I compile the trigger with the code change, I'm getting an ORA-04084: cannot change NEW values for this trigger type. Is there a way of achieving this with this type of trigger? This is an existing trigger in our application and we're trying to avoid adding a new trigger. Here is the code I was trying to compile in the trigger.
:NEW.FUND_NAME := trim(regexp_replace(replace(replace(:NEW.FUND_NAME, chr(13), null), chr(160), chr(32)), ' {2,}',' '));
This post has been answered by JustinCave on May 30 2013
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 27 2013
Added on May 30 2013
13 comments
2,008 views