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 the DUAL table in subquery of UPDATE

1005809Apr 26 2013 — edited Apr 26 2013
Should the following code work? I feel like I have done this before, but I'm getting a "must be a subquery" error now.

update TABLE1
set (FIELD1, FIELD2) =
values(select 'blah','blah' from DUAL)
where PK_FIELD=12345;

If this is invalid, is there another way to hardcode a series of values like this?


Thanks in advance.

Edited by: user8031991 on Apr 26, 2013 11:57 AM
This post has been answered by Frank Kulash on Apr 26 2013
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 24 2013
Added on Apr 26 2013
8 comments
1,534 views