agora inbox for pgsql-sql@postgresql.org
help / color / mirror / Atom feedFrom: Benoit Menendez <benoitm@pacbell.net>
To: pgsql-sql@postgresql.org
Subject: Problem with self-join updates...
Date: Tue, 19 Feb 2002 10:32:06 -0800
Message-ID: <002b01c1b973$bf48c740$0201a8c0@osprey> (raw)
References: <002101c1b650$18f087a0$0201a8c0@osprey>
Can someone please help?
Benoit
----- Original Message -----
From: Benoit Menendez
To: pgsql-sql@postgresql.org
Sent: Friday, February 15, 2002 10:39 AM
Subject: [SQL] Problem with self-join updates...
I have the following self-join update:
update TABLE set PARENT_ID=parent.PARENT_ID
from TABLE, TABLE parent
where TABLE.PARENT_ID=parent.ID
and parent.ID in (1,2,3,4)
This query is use to update a hierarchy before deleting specific records...
I get the following error:
Table name "table" specified more than once
This appears to be a limitation of the update syntax which is not documented...
Is this something that will be fixed soon? or should I write this query differently?
Any suggestions?
Thanks for your help.
Benoit
view thread (5+ messages) latest in thread
Message-ID: <002b01c1b973$bf48c740$0201a8c0@osprey>
Permalink: ../002b01c1b973$bf48c740$0201a8c0@osprey/
Also on: postgresql.org/message-id/002b01c1b973$bf48c740$0201a8c0@osprey
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: benoitm@pacbell.net
Subject: Re: Problem with self-join updates...
In-Reply-To: <002b01c1b973$bf48c740$0201a8c0@osprey>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox