Re: [SQL] qurey plan and indices - Mailing list pgsql-sql

From MESZAROS Attila
Subject Re: [SQL] qurey plan and indices
Date
Msg-id Pine.LNX.3.96.990805165414.26220B-100000@chiara.csoma.elte.hu
Whole thread Raw
In response to Re: [SQL] qurey plan and indices  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-sql
> However, the *real* problem here is that the inner query is treated
> as a subplan, which means it is re-evaluated for each tuple scanned
> by the outer query.  This is not very bright; the system ought to
> notice that the inner query does not depend on the state of the
> outer query, and do it only once.  There is already a notion of
> InitPlan vs. SubPlan.  I'm not sure why this case is being classified
> as a SubPlan, but it sure looks like it ought to be done as an
> InitPlan...So this means, it is a bug somewhere in the planner?who should we report this??

Attila

any workarounds?
[better than temptables?]



pgsql-sql by date:

Previous
From: MESZAROS Attila
Date:
Subject: Re: [SQL] qurey plan and indices
Next
From: rob caSSon
Date:
Subject: Re: [SQL] primary key view failure