Re: BUG #18468: CREATE TABLE ... LIKE leaves orphaned column reference in extended statistics

From: Tender Wang <tndrwang(at)gmail(dot)com>
To: exclusion(at)gmail(dot)com, pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: BUG #18468: CREATE TABLE ... LIKE leaves orphaned column reference in extended statistics
Date: 2024-05-16 08:38:19
Message-ID: CAHewXNkng5jG472hh+icVT_g8BT5Gv4tNFjBP_X5cK1aqiH=ag@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

generateClonedExtStatsStmt just copy t0's ext_stat info to t1.
I think we could do something in transformExtendedStatistics() as the
comments said.
in transformCreateStmt, has below code:
/*
* Postprocess extended statistics.
*/
transformExtendedStatistics(&cxt);

Right now, there is nothing to do in transformExtendedStatistics.
Can we update the varattno to the right value here?
--
Tender Wang
OpenPie: https://en.openpie.com/

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Önder Kalacı 2024-05-16 09:02:27 Re: BUG #18467: postgres_fdw (deparser) ignores LimitOption
Previous Message Bowen Shi 2024-05-16 07:31:20 Re: relfrozenxid may disagree with row XIDs after 1ccc1e05ae