Re: [HACKERS] TIME QUALIFICATION - Mailing list pgsql-hackers

From Vadim Mikheev
Subject Re: [HACKERS] TIME QUALIFICATION
Date
Msg-id 36C39138.2DF38421@krs.ru
Whole thread Raw
In response to Re: [HACKERS] TIME QUALIFICATION  (jwieck@debis.com (Jan Wieck))
List pgsql-hackers
Jan Wieck wrote:
> 
>     So  I  assume  the sublink->subselect, that's copied into the
>     plan, is totally obsolete too at that point. The subplan  has
>     it's  own rangetable, which is the same as the (not used) one
>     in the subselect.

Exactly.

>     I think I should tidy up that all to finally pass  only  plan
>     into  executor  before  going  ahead  with the deferred query
>     stuff. It doesn't make sense to  spend  much  efford  now  to
>     prepare  the system for deferred queries. It depends too much
>     on where the RTE's are and how we organize them.
> 
>     New TopPlan could be passed  down  the  executor  instead  of
>     querytree.  It  might  hold  a  List of rangetables. Plan and
>     SubPlan then have an index telling which nth() rangetable  of
>     TopPlan to use for it.
> 
>     This  would  make  execution  preprocessing for snapshot->RTE
>     assignment very easy because there's only one place  to  find
>     ALL  RTE's  (no  need  to traverse down a tree). And it would
>     substantial lower the amount of data to copy in SPI, since it
>     must not save the Querytree at all.

Nice!

Vadim


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [HACKERS] VACUUM ANALYZE problem on linux
Next
From: "Thomas G. Lockhart"
Date:
Subject: Re: [HACKERS] Type conversion