pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix planner failure with extended statistics on partitioned tabl
Date: Tue, 01 Nov 2022 18:34:56 +0000
Message-ID: <E1opw6C-001nuA-82@gemulon.postgresql.org> (raw)

Fix planner failure with extended statistics on partitioned tables.

Some cases would result in "cache lookup failed for statistics object",
due to trying to fetch inherited statistics when only non-inherited
ones are available or vice versa.

Richard Guo and Justin Pryzby

Discussion: https://postgr.es/m/20221030170520.GM16921@telsasoft.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/f4857082bc16f36a5cdc6f8328cdc8071bb1715e

Modified Files
--------------
src/backend/utils/adt/selfuncs.c        | 11 +++++++++--
src/test/regress/expected/stats_ext.out |  8 +++++++-
src/test/regress/sql/stats_ext.sql      |  3 ++-
3 files changed, 18 insertions(+), 4 deletions(-)



view thread (2+ messages)

Message-ID: <E1opw6C-001nuA-82@gemulon.postgresql.org>
Permalink:  ../E1opw6C-001nuA-82@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1opw6C-001nuA-82@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us
  Subject: Re: pgsql: Fix planner failure with extended statistics on partitioned tabl
  In-Reply-To: <E1opw6C-001nuA-82@gemulon.postgresql.org>
  References: <E1opw6C-001nuA-82@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox