Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: update multi column
c.undieseastwood_at_gu.edu.au (Chris East wood) wrote:
>HiYa
>
>I have 2 tables, A is data, and B is fixed data. I wanted to update more than
>one colum of table A with a corresponding row's information from B.
>
>there is only 1 key.
>
>I can't quite figure how to do it damnit its late and I'm fed up! :-)
>
>IE something like
>
>update A
>set IDN = (select idn from B where A.key = B.key)
>where A.key = B.key
>
>
Try
Update A set idn = (select idn from B where A key = B key), idx = (select idx
from B where Akey = B key), etc.......
Separate the column names and the expressions used to update them by commas and
then you need only one SET command...
To reply please remove the 'nospam' part of the address
Received on Wed Dec 02 1998 - 10:23:32 CST
![]() |
![]() |