Re: Odd system-column handling in postgres_fdw join pushdown patch

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Etsuro Fujita <fujita(dot)etsuro(at)lab(dot)ntt(dot)co(dot)jp>
Cc: Ashutosh Bapat <ashutosh(dot)bapat(at)enterprisedb(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Odd system-column handling in postgres_fdw join pushdown patch
Date: 2016-04-14 04:04:00
Message-ID: CA+TgmoYm8zbrhrd7tRuMP9+5T0ihN+vW23OsveWbS7XquJg=JQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Apr 13, 2016 at 11:21 PM, Etsuro Fujita
<fujita(dot)etsuro(at)lab(dot)ntt(dot)co(dot)jp> wrote:
>>> 2. When a join is pushed down, deparse system columns using something
>>> like "CASE WHEN r1.* IS NOT NULL THEN 0 END", except for the table OID
>>> column, which gets deparsed with the table OID in place of 0. This
>>> delivers the correct behavior in the presence of outer joins.
>> I think that that would cause useless data transfer for such culumns.
>> Why not set values locally for such columns?

Because that doesn't work properly when there are outer joins
involved. I see no other way of doing that correctly that's anywhere
near as simple as this.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kyotaro HORIGUCHI 2016-04-14 04:11:10 Re: Support for N synchronous standby servers - take 2
Previous Message Fujii Masao 2016-04-14 03:42:06 Re: Support for N synchronous standby servers - take 2