Re: foreign join error "variable not found in subplan target list"

From: Etsuro Fujita <etsuro(dot)fujita(at)gmail(dot)com>
To: Richard Guo <guofenglinux(at)gmail(dot)com>
Cc: Alexander Pyhalov <a(dot)pyhalov(at)postgrespro(dot)ru>, PostgreSQL mailing lists <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: foreign join error "variable not found in subplan target list"
Date: 2022-08-29 06:18:17
Message-ID: CAPmGK15Z3G-MLSqmS5sz=X7=g3DzReWiRwprc4UW-kTDw6oOZg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Mon, Aug 22, 2022 at 12:29 PM Richard Guo <guofenglinux(at)gmail(dot)com> wrote:
> On Sun, Aug 21, 2022 at 8:31 PM Etsuro Fujita <etsuro(dot)fujita(at)gmail(dot)com> wrote:
>> * I think we should avoid modifying the pathtarget, because it would
>> be the default pathtarget, which other paths might reference. I think
>> it’s safe to use a copied pathtarget, like the attached.

> Yeah, that's right. The EPQ path is a shallow copy of the original. A
> copied pathtarget should be saner here.

One thing I noticed while re-reading the patch is that we should use
create_projection_path() here, to avoid modifying the epq_path in
place, as it is already used for an unsorted join-pushdown path before
we get here. So I modified the patch as such. Updated patch
attached.

Thanks for reviewing!

Best regards,
Etsuro Fujita

Attachment Content-Type Size
v1-0001-Include-local-conds-in-epq-pathtarget-efujita-2.patch application/octet-stream 12.1 KB

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message PG Bug reporting form 2022-08-29 08:54:59 BUG #17600: Not able to install PostgreSql in my laptop
Previous Message jitesh tiwari 2022-08-29 06:01:48 Re: fetching bytea (blob) data of 850 MB from psql client failed