Re: Early WIP/PoC for inlining CTEs - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Early WIP/PoC for inlining CTEs
Date
Msg-id 20180808050211.ep44572t4lsqj35g@alap3.anarazel.de
Whole thread Raw
In response to Re: Early WIP/PoC for inlining CTEs  (Thomas Munro <thomas.munro@enterprisedb.com>)
Responses Re: Early WIP/PoC for inlining CTEs
List pgsql-hackers
Hi,

On 2018-08-08 16:55:22 +1200, Thomas Munro wrote:
> On Fri, Jul 27, 2018 at 8:10 PM, David Fetter <david@fetter.org> wrote:
> > On Fri, Jul 27, 2018 at 02:55:26PM +1200, Thomas Munro wrote:
> >> On Thu, Jul 26, 2018 at 7:14 AM, David Fetter <david@fetter.org> wrote:
> >> > Please find attached the next version, which passes 'make check'.
> >>
> >> ... but not 'make check-world' (contrib/postgres_fdw's EXPLAIN is different).
> >
> > Please find attached a patch that does.
> >
> > It doesn't always pass make installcheck-world, but I need to sleep
> > rather than investigate that at the moment.
> 
> One observation I wanted to share: CTE scans inhibit parallelism today
> (something we might eventually want to fix with shared tuplestores).
> This patch therefore allows parallelism in some WITH queries, which
> seems like a very valuable thing.

Might be interesting to see how big a difference it makes for
TPC-DS. Currently the results are bad (as in many queries don't finish
in a relevant time) because it uses CTEs so widely, and there's often
predicates outside the CTE that could be pushed down.

- Andres


pgsql-hackers by date:

Previous
From: Thomas Munro
Date:
Subject: Re: Early WIP/PoC for inlining CTEs
Next
From: Amit Langote
Date:
Subject: Re: Internal error XX000 with enable_partition_pruning=on, pg 11beta1 on Debian