From: | David Rowley <david(dot)rowley(at)2ndquadrant(dot)com> |
---|---|
To: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
Cc: | Simon Riggs <simon(at)2ndquadrant(dot)com>, Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Robert Haas <robertmhaas(at)gmail(dot)com>, Amit Langote <amitlangote09(at)gmail(dot)com>, Amit Khandekar <amitdkhan(dot)pg(at)gmail(dot)com> |
Subject: | Re: Needless additional partition check in INSERT? |
Date: | 2018-06-07 00:00:44 |
Message-ID: | CAKJS1f-7SXmdSgVeZF_f-77ovnRru9hWjdYCBHS-eMW6fGJ-ew@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 7 June 2018 at 09:08, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> wrote:
> I wonder if we should create a new small function that takes the two
> resultRelInfos and returns the correct boolean --maybe something like
> ExecConstraintsPartConstrNeedsRecheck()-- and then the smarts are in a
> single place and we diminish the risk of a divergence. It looks like a
> very ad-hoc thing to have a function for, but then the new argument to
> ExecConstraints() *is* pretty ad-hoc already, so encapsulating it seems
> better.
Hi Alvaro,
Thanks for looking at this. I thought it was strange to pass in both
resultRelInfos. I ended up just making the 2nd param a bool to
indicate of tuple routing was used.
I'm personally not really for or against having the function. I agree
that it's slightly weird, but anyway, here's the patch. I'll leave it
up to you to which one you prefer, v3 or v4.
--
David Rowley http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
Attachment | Content-Type | Size |
---|---|---|
remove_needless_additional_partition_check_v4.patch | application/octet-stream | 5.5 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | David Rowley | 2018-06-07 00:11:37 | Re: Spilling hashed SetOps and aggregates to disk |
Previous Message | Claudio Freire | 2018-06-06 23:29:55 | Re: POC: GROUP BY optimization |