1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-14 18:42:34 +03:00

Add the ability to store inheritance-tree statistics in pg_statistic,

and teach ANALYZE to compute such stats for tables that have subclasses.
Per my proposal of yesterday.

autovacuum still needs to be taught about running ANALYZE on parent tables
when their subclasses change, but the feature is useful even without that.
This commit is contained in:
Tom Lane
2009-12-29 20:11:45 +00:00
parent 84d723b6ce
commit 649b5ec7c8
18 changed files with 407 additions and 177 deletions

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/utils/cache/syscache.c,v 1.121 2009/10/05 19:24:45 tgl Exp $
* $PostgreSQL: pgsql/src/backend/utils/cache/syscache.c,v 1.122 2009/12/29 20:11:45 tgl Exp $
*
* NOTES
* These routines allow the parser/planner/executor to perform
@ -597,14 +597,14 @@ static const struct cachedesc cacheinfo[] = {
},
1024
},
{StatisticRelationId, /* STATRELATT */
StatisticRelidAttnumIndexId,
{StatisticRelationId, /* STATRELATTINH */
StatisticRelidAttnumInhIndexId,
Anum_pg_statistic_starelid,
2,
3,
{
Anum_pg_statistic_starelid,
Anum_pg_statistic_staattnum,
0,
Anum_pg_statistic_stainherit,
0
},
1024