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 %ROWTYPE in update and insert statements?

98007Jan 10 2002
Hi,

I'm fairly new to PL/SQL and have a question about %ROWTYPE.
I have created a cursor from table rates_update and am using %ROWTYPE named rates_update_rec.

In the cursor, for each rates_update_rec I am updating another
table...for example:
UPDATE rates
SET column1 = rates_update_rec.column1,
column2 = rates_update_rec.column2,
...etc.

This works fine.

Is there a way to just use the rates_update_rec without having
to specify each row in the SET clause? I'm also interested to know if this is possible in INSERT statement.

Best Regards,
Brian
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 7 2002
Added on Jan 10 2002
2 comments
476 views