Re: NOT IN subquery optimization

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Jim Finnerty <jfinnert(at)amazon(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: NOT IN subquery optimization
Date: 2019-02-21 00:40:44
Message-ID: 8724.1550709644@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Jim Finnerty <jfinnert(at)amazon(dot)com> writes:
> We have been working on improved optimization of NOT IN, and we would like
> to share this optimizaton with the community.

The idea that's been kicked around in the past is to detect whether the
subselect's output column(s) can be proved NOT NULL, and if so, convert
to an antijoin just like NOT EXISTS. Is that what you're doing, or
something different?

> We would like to include a patch for this change in the current commitfest.

Generally, people just send patches, they don't ask for permission first
;-)

Having said that, we have a general policy that we don't like complex
patches that first show up for the last commitfest of a dev cycle.
So unless this is a pretty small patch, it's probably going to get
delayed to v13. Still, we'd like to have it in the queue, so submit
away ...

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Geoghegan 2019-02-21 00:56:31 Re: amcheck verification for GiST
Previous Message Simon Riggs 2019-02-21 00:37:18 Re: propagating replica identity to partitions