Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.tools -> Re: Can you specify multiple tables in update's where clause?
Try nested queries:
(untested SQL ahead)
UPDATE TABLE_A
SET TABLE_A.my_col = "thisThat"
WHERE
TABLE_A.col_a = (select col_b from TABLE_X where col_b = TABLE_A.col_a
and col_c = (select col_d from TABLE_Y where TABLE_X.col_c = col_d))
Christopher Latta
change <changeme_at_changeme> wrote in message
news:9ei2f5$dh01_at_kcweb01.netnews.att.com...
> Need some sql expert input on UPDATE command. How do I involve multiple
> tables in WHERE clause?
>
> Consider this simplified example on update command:
>
> UPDATE TABLE_A
> SET TABLE_A.my_col = "thisThat"
> WHERE
> TABLE_A.col_a = TABLE_X.col_b
> and TABLE_X.col_c = TABLE_Y.col_d
Received on Wed May 23 2001 - 23:56:16 CDT