Re: BUG #17811: Replacing an underlying view breaks OLD/NEW tuple when accessing it via upper-level view

From: Alexander Lakhin <exclusion(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: BUG #17811: Replacing an underlying view breaks OLD/NEW tuple when accessing it via upper-level view
Date: 2023-03-08 06:00:00
Message-ID: b941ef12-c466-2eee-c3d4-f3c882ec0d16@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

07.03.2023 21:43, Tom Lane wrote:
> I've looked into this a bit more, and both of these symptoms reduce
> to the same thing: after we've plugged the modified view's query
> into the upper query, we have an RTE_SUBQUERY RTE whose eref->colnames
> list is shorter than the number of columns actually available from the
> subquery. This breaks assorted code that is expecting that it can
> use list_length(eref->colnames) as a quick guide to the number of
> output columns.

Thanks for the fix!
I've tested all my cases on REL_15_STABLE, master and found no
anomalies in this area.

Best regards,
Alexander

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Francisco Olarte 2023-03-08 09:55:36 Re: pg_basebackup fails with Could not stat file or directory "./.pg_hba.conf.un~"
Previous Message Jeff Davis 2023-03-08 05:49:12 unaccent fails when datlocprovider=i and datctype=C