pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedERROR: plan should not reference subplan's variable
5+ messages / 3 participants
[nested] [flat]
* ERROR: plan should not reference subplan's variable
@ 2006-05-02 19:13 Catalin Pitis <cpitis.pgsql@gmail.com>
2006-05-02 20:17 ` Re: ERROR: plan should not reference subplan's variable Tom Lane <tgl@sss.pgh.pa.us>
2006-05-03 01:28 ` Re: ERROR: plan should not reference subplan's variable Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 2 replies; 5+ messages in thread
From: Catalin Pitis @ 2006-05-02 19:13 UTC (permalink / raw)
To: pgsql-sql
Hi *
I'm trying to run the following SQL statement on a PostgreSQL 8.1, installed
on a Windows machine:
INSERT INTO PROJECT(PROJECT_ID,PROJECT_DESC)
(
SELECT MAX(PROJECT_ID),'MYPROJECT'
FROM PROJECT
WHERE NOT EXISTS
(
SELECT PROJECT_DESC FROM PROJECT WHERE PROJECT_DESC = 'MYPROJECT'
)
)
and I get the following error:
ERROR: plan should not reference subplan's variable
If, for example, I replace MAX with some other aggregation (e.g. AVG or
SUM), everything works ok.
The table DDL looks like:
CREATE TABLE project
(
project_id int4 NOT NULL,
project_desc varchar(255),
CONSTRAINT project_pkey PRIMARY KEY (project_id)
)
WITH OIDS;
Do you have any clue why does this happen?
Thanks,
Catalin
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: ERROR: plan should not reference subplan's variable
2006-05-02 19:13 ERROR: plan should not reference subplan's variable Catalin Pitis <cpitis.pgsql@gmail.com>
@ 2006-05-02 20:17 ` Tom Lane <tgl@sss.pgh.pa.us>
1 sibling, 0 replies; 5+ messages in thread
From: Tom Lane @ 2006-05-02 20:17 UTC (permalink / raw)
To: Catalin Pitis <cpitis.pgsql@gmail.com>; +Cc: pgsql-sql
"Catalin Pitis" <cpitis.pgsql@gmail.com> writes:
> ERROR: plan should not reference subplan's variable
> Do you have any clue why does this happen?
It's a bug :-(. Thanks for the test case --- I'll look into it tonight
or tomorrow, if no one beats me to it.
regards, tom lane
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: ERROR: plan should not reference subplan's variable
2006-05-02 19:13 ERROR: plan should not reference subplan's variable Catalin Pitis <cpitis.pgsql@gmail.com>
@ 2006-05-03 01:28 ` Tom Lane <tgl@sss.pgh.pa.us>
2006-05-03 05:08 ` Re: ERROR: plan should not reference subplan's variable Catalin Pitis <cpitis.pgsql@gmail.com>
1 sibling, 1 reply; 5+ messages in thread
From: Tom Lane @ 2006-05-03 01:28 UTC (permalink / raw)
To: Catalin Pitis <cpitis.pgsql@gmail.com>; +Cc: pgsql-sql
"Catalin Pitis" <cpitis.pgsql@gmail.com> writes:
> ERROR: plan should not reference subplan's variable
I've applied a patch for this; will be in 8.1.4.
http://archives.postgresql.org/pgsql-committers/2006-05/msg00016.php
regards, tom lane
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: ERROR: plan should not reference subplan's variable
2006-05-02 19:13 ERROR: plan should not reference subplan's variable Catalin Pitis <cpitis.pgsql@gmail.com>
2006-05-03 01:28 ` Re: ERROR: plan should not reference subplan's variable Tom Lane <tgl@sss.pgh.pa.us>
@ 2006-05-03 05:08 ` Catalin Pitis <cpitis.pgsql@gmail.com>
2006-05-03 11:51 ` Re: ERROR: plan should not reference subplan's variable Andrew Sullivan <ajs@crankycanuck.ca>
0 siblings, 1 reply; 5+ messages in thread
From: Catalin Pitis @ 2006-05-03 05:08 UTC (permalink / raw)
To: pgsql-sql
Hi Tom
Could you tell me when will 8.1.4 be released with the problem solved?
Thanks,
Catalin
On 5/3/06, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>
> "Catalin Pitis" <cpitis.pgsql@gmail.com> writes:
> > ERROR: plan should not reference subplan's variable
>
> I've applied a patch for this; will be in 8.1.4.
>
> http://archives.postgresql.org/pgsql-committers/2006-05/msg00016.php
>
> regards, tom lane
>
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: ERROR: plan should not reference subplan's variable
2006-05-02 19:13 ERROR: plan should not reference subplan's variable Catalin Pitis <cpitis.pgsql@gmail.com>
2006-05-03 01:28 ` Re: ERROR: plan should not reference subplan's variable Tom Lane <tgl@sss.pgh.pa.us>
2006-05-03 05:08 ` Re: ERROR: plan should not reference subplan's variable Catalin Pitis <cpitis.pgsql@gmail.com>
@ 2006-05-03 11:51 ` Andrew Sullivan <ajs@crankycanuck.ca>
0 siblings, 0 replies; 5+ messages in thread
From: Andrew Sullivan @ 2006-05-03 11:51 UTC (permalink / raw)
To: pgsql-sql
On Wed, May 03, 2006 at 08:08:22AM +0300, Catalin Pitis wrote:
> Hi Tom
>
> Could you tell me when will 8.1.4 be released with the problem solved?
In general, you can't rely on hard release dates in a free software
project. Given that's in the STABLE branch, however, you could get
it directly from CVS and build it yourself. Directions for doing
this are on the website (possibly in the developer's section, note).
A
--
Andrew Sullivan | ajs@crankycanuck.ca
The whole tendency of modern prose is away from concreteness.
--George Orwell
^ permalink raw reply [nested|flat] 5+ messages in thread
end of thread, other threads:[~2006-05-03 11:51 UTC | newest]
Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-05-02 19:13 ERROR: plan should not reference subplan's variable Catalin Pitis <cpitis.pgsql@gmail.com>
2006-05-02 20:17 ` Tom Lane <tgl@sss.pgh.pa.us>
2006-05-03 01:28 ` Tom Lane <tgl@sss.pgh.pa.us>
2006-05-03 05:08 ` Catalin Pitis <cpitis.pgsql@gmail.com>
2006-05-03 11:51 ` Andrew Sullivan <ajs@crankycanuck.ca>
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