From: | David Rowley <dgrowleyml(at)gmail(dot)com> |
---|---|
To: | Noah Misch <noah(at)leadboat(dot)com> |
Cc: | PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Dilip kumar <dilip(dot)kumar(at)huawei(dot)com> |
Subject: | Re: Allowing join removals for more join types |
Date: | 2014-06-17 10:04:39 |
Message-ID: | CAApHDvr-3quZ4pXRn-Qo_ccw5wsmkwT9T_ShR_Jnpf3HfKAyTw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Jun 4, 2014 at 12:50 AM, Noah Misch <noah(at)leadboat(dot)com> wrote:
> As a point of procedure, I recommend separating the semijoin support into
> its
> own patch. Your patch is already not small; delaying non-essential parts
> will
> make the essential parts more accessible to reviewers.
>
>
In the attached patch I've removed all the SEMI and ANTI join removal code
and left only support for LEFT JOIN removal of sub-queries that can be
proved to be unique on the join condition by looking at the GROUP BY and
DISTINCT clause.
Example:
SELECT t1.* FROM t1 LEFT OUTER JOIN (SELECT value,COUNT(*) FROM t2 GROUP BY
value) t2 ON t1.id = t2.value;
Regards
David Rowley
Attachment | Content-Type | Size |
---|---|---|
subquery_leftjoin_removal_v1.1.patch | application/octet-stream | 17.2 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Andres Freund | 2014-06-17 10:26:58 | Re: Wait free LW_SHARED acquisition - v0.2 |
Previous Message | Michael Paquier | 2014-06-17 09:30:30 | Re: IMPORT FOREIGN SCHEMA statement |