pg.ddx.io pgsql-docs@postgresql.org mailing list archive
help / color / mirror / Atom feedEmpty values of pg_stats_ext when table is empty
2+ messages / 2 participants
[nested] [flat]
* Empty values of pg_stats_ext when table is empty
@ 2021-11-01 13:23 PG Doc comments form <noreply@postgresql.org>
2022-08-17 14:32 ` Re: Empty values of pg_stats_ext when table is empty Bruce Momjian <bruce@momjian.us>
0 siblings, 1 reply; 2+ messages in thread
From: PG Doc comments form @ 2021-11-01 13:23 UTC (permalink / raw)
To: pgsql-docs@lists.postgresql.org; +Cc: stefan.keller@ost.ch
The following documentation comment has been logged on the website:
Page: https://www.postgresql.org/docs/14/view-pg-stats-ext.html
Description:
When table mytable is being inherited it may not contain any data but still
return row sets from the inheriting tables. Now doing CREATE STATISTICS on
mytable will work but won't have any values.
This is very difficult to realize from a user's perspective and can be
either considered a feature or a bug, i.e. being enhanced.
Given this is considered as a feature, I suggest to add a comment at the end
of this documentation
https://www.postgresql.org/docs/current/view-pg-stats-ext.html like this:
<<
Note then there are no values when the table is empty which happens when
there are tables which inherit from it.
<<
I could also think of a run-time warning?
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: Empty values of pg_stats_ext when table is empty
2021-11-01 13:23 Empty values of pg_stats_ext when table is empty PG Doc comments form <noreply@postgresql.org>
@ 2022-08-17 14:32 ` Bruce Momjian <bruce@momjian.us>
0 siblings, 0 replies; 2+ messages in thread
From: Bruce Momjian @ 2022-08-17 14:32 UTC (permalink / raw)
To: stefan.keller@ost.ch; pgsql-docs@lists.postgresql.org; +Cc: Tomas Vondra <tomas.vondra@enterprisedb.com>
On Mon, Nov 1, 2021 at 01:23:01PM +0000, PG Doc comments form wrote:
> The following documentation comment has been logged on the website:
>
> Page: https://www.postgresql.org/docs/14/view-pg-stats-ext.html
> Description:
>
> When table mytable is being inherited it may not contain any data but still
> return row sets from the inheriting tables. Now doing CREATE STATISTICS on
> mytable will work but won't have any values.
>
> This is very difficult to realize from a user's perspective and can be
> either considered a feature or a bug, i.e. being enhanced.
>
> Given this is considered as a feature, I suggest to add a comment at the end
> of this documentation
> https://www.postgresql.org/docs/current/view-pg-stats-ext.html like this:
>
> <<
> Note then there are no values when the table is empty which happens when
> there are tables which inherit from it.
> <<
>
> I could also think of a run-time warning?
I talked to Tomas Vondra and he says there will be proper parent
statistics in PG 15, due to be released in the next 1-2 months. Here is
the PG 15 release note item:
https://www.postgresql.org/docs/15/release-15.html
Allow extended statistics to record statistics for a parent with all its
children (Tomas Vondra, Justin Pryzby)
Regular statistics already tracked parent and parent/all-children
statistics separately.
--
Bruce Momjian <bruce@momjian.us> https://momjian.us
EDB https://enterprisedb.com
Indecision is a decision. Inaction is an action. Mark Batterson
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2022-08-17 14:32 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2021-11-01 13:23 Empty values of pg_stats_ext when table is empty PG Doc comments form <noreply@postgresql.org>
2022-08-17 14:32 ` Bruce Momjian <bruce@momjian.us>
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