Re: extended stats on partitioned tables

From: Justin Pryzby <pryzby(at)telsasoft(dot)com>
To: Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com>
Cc: Zhihong Yu <zyu(at)yugabyte(dot)com>, Jaime Casanova <jcasanov(at)systemguards(dot)com(dot)ec>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: extended stats on partitioned tables
Date: 2021-12-12 21:49:15
Message-ID: 20211212214915.GQ17618@telsasoft.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sun, Dec 12, 2021 at 10:29:39PM +0100, Tomas Vondra wrote:
> On 12/12/21 18:52, Justin Pryzby wrote:
> That's mostly a conscious choice, so that I don't have to include
> parsetree.h. But maybe that'd be better ...
>
> > The regression tests changed as a result of not populating stx_data; I think
> > it's may be better to update like this:
> >
> > SELECT stxname, stxdndistinct, stxddependencies, stxdmcv, stxoid IS NULL
> > FROM pg_statistic_ext s LEFT JOIN pg_statistic_ext_data d
> > ON d.stxoid = s.oid
> > WHERE s.stxname = 'ab1_a_b_stats';
> >
>
> Not sure I understand. Why would this be better than inner join?

It shows that there's an entry in pg_statistic_ext and not one in ext_data,
rather than that it's not in at least one of the catalogs. Which is nice to
show since as you say it's no longer 1:1.

> Thanks, fixed. Can you read through the commit messages and check the
> attribution is correct for all the patches?

Seems fine.

--
Justin

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2021-12-12 21:52:48 Re: [PATCH] pg_stat_toast
Previous Message Justin Pryzby 2021-12-12 21:32:10 Re: extended stats on partitioned tables