Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: SQL help needed
UPDATE a SET city =
(SELECT b.city
FROM b
WHERE b.personnr = a.personnr)
WHERE EXISTS
(SELECT 'x'
FROM b
WHERE b.personnr = a.personnr)
Cheers
Allan
"Gert Ensing" <g.c.ensing_at_castel.nl> wrote in message
news:959jjb$th0$1_at_news.castel.nl...
> I have to tables :
>
> Table A and table B
>
> A
> =
> Personnr
> Name
> City
>
> B
> =
> Personnr
> City
>
> I like to fill A.City with B.city for all records in A where the
personnr's
> are equal.
>
> In MS-Access I use the statement :
>
> UPDATE A INNER JOIN B ON [a].[personnr]=[b].[personnr] SET a.city=b.city
>
> but this doesn't work in Oracle.
>
> Please help ! (Send me an email to : g.c.ensing_at_castel.nl)
>
> Thanks in advance,
> Gert
>
>
Received on Wed Jan 31 2001 - 15:37:14 CST
![]() |
![]() |