diff options
| author | Tom Lane | 2004-02-15 21:01:39 +0000 |
|---|---|---|
| committer | Tom Lane | 2004-02-15 21:01:39 +0000 |
| commit | f0c9397f808531b4207ebe60ff3ba9b038812443 (patch) | |
| tree | 66d756d316f0d045dd6d0a756315efb6ed99b878 /src/include | |
| parent | 4b8f1259738458e35a147820232bc7aab4f85e5c (diff) | |
First steps towards statistics on expressional (nee functional) indexes.
This commit teaches ANALYZE to store such stats in pg_statistic, but
nothing is done yet about teaching the planner to use 'em.
Also, repair longstanding oversight in separate ANALYZE command: it
updated the pg_class.relpages and reltuples counts for the table proper,
but not for indexes.
Diffstat (limited to 'src/include')
| -rw-r--r-- | src/include/catalog/heap.h | 3 | ||||
| -rw-r--r-- | src/include/commands/vacuum.h | 7 |
2 files changed, 7 insertions, 3 deletions
diff --git a/src/include/catalog/heap.h b/src/include/catalog/heap.h index b14d1427520..741b0a129e6 100644 --- a/src/include/catalog/heap.h +++ b/src/include/catalog/heap.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/catalog/heap.h,v 1.63 2003/11/29 22:40:58 pgsql Exp $ + * $PostgreSQL: pgsql/src/include/catalog/heap.h,v 1.64 2004/02/15 21:01:39 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -69,6 +69,7 @@ extern void RemoveAttributeById(Oid relid, AttrNumber attnum); extern void RemoveAttrDefault(Oid relid, AttrNumber attnum, DropBehavior behavior, bool complain); extern void RemoveAttrDefaultById(Oid attrdefId); +extern void RemoveStatistics(Relation rel, AttrNumber attnum); extern Form_pg_attribute SystemAttributeDefinition(AttrNumber attno, bool relhasoids); diff --git a/src/include/commands/vacuum.h b/src/include/commands/vacuum.h index 8c58f1ac385..9abb09948f6 100644 --- a/src/include/commands/vacuum.h +++ b/src/include/commands/vacuum.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/commands/vacuum.h,v 1.50 2004/02/13 06:39:49 tgl Exp $ + * $PostgreSQL: pgsql/src/include/commands/vacuum.h,v 1.51 2004/02/15 21:01:39 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -106,8 +106,11 @@ typedef struct VacAttrStats * be looked at by type-specific functions. */ int tupattnum; /* attribute number within tuples */ - HeapTuple *rows; /* access info for fetch function */ + HeapTuple *rows; /* access info for std fetch function */ TupleDesc tupDesc; + Datum *exprvals; /* access info for index fetch function */ + bool *exprnulls; + int rowstride; } VacAttrStats; |
