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!

returning old value in returning clause in an Update statement

sk12345678Aug 29 2011 — edited Aug 29 2011
Is it possible that I can get the old values in a returning clause into variable col1_array. Currently I am getting the new values of col1 (after update) into col1_Array

UPDATE table1
SET col1= CASE
WHEN (in_col2 IS NULL )
col1 + 1
WHEN (in_col3 IS NULL ) THEN
col1 -1
where col3 = 1234
RETURNING col1 BULK COLLECT INTO col1_array;

Appreciate your responses. Thanks

Edited by: rajugopalli on Aug 29, 2011 12:53 PM
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 26 2011
Added on Aug 29 2011
8 comments
4,966 views