pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedhow to simulate UPdate ...?
2+ messages / 2 participants
[nested] [flat]
* how to simulate UPdate ...?
@ 2001-02-01 18:01 guard <guard@ficnet.net>
0 siblings, 1 reply; 2+ messages in thread
From: guard @ 2001-02-01 18:01 UTC (permalink / raw)
To: pgsql-sql
I not run update.... in Pgsql
please tell me other method
thanks
======================================
update table1 a set na1=
(select table2.na1 from table2,table1
where table1.no=table2.no
and a.no=table1.no);
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: how to simulate UPdate ...?
@ 2001-02-06 00:37 Stephan Szabo <sszabo@megazone23.bigpanda.com>
parent: guard <guard@ficnet.net>
0 siblings, 0 replies; 2+ messages in thread
From: Stephan Szabo @ 2001-02-06 00:37 UTC (permalink / raw)
To: guard <guard@ficnet.net>; +Cc: pgsql-sql
Isn't this equivalent to?
update table1 set na1=
(select table2.na1 from table2 where
table1.no=table2.no);
Which can also be invalid if there can be
multiple rows returned by the subselect
since there'd be no way to know which
table2.na1 you'd want without more info.
On Fri, 2 Feb 2001, guard wrote:
> I not run update.... in Pgsql
>
> please tell me other method
> thanks
>
> ======================================
> update table1 a set na1=
> (select table2.na1 from table2,table1
> where table1.no=table2.no
> and a.no=table1.no);
>
>
>
>
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2001-02-06 00:37 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-02-01 18:01 how to simulate UPdate ...? guard <guard@ficnet.net>
2001-02-06 00:37 ` Stephan Szabo <sszabo@megazone23.bigpanda.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox