19#define STATS_MAX_DIMENSIONS 8
22#define STATS_NDISTINCT_MAGIC 0xA352BFA4
23#define STATS_NDISTINCT_TYPE_BASIC 1
43#define STATS_DEPS_MAGIC 0xB4549A2C
44#define STATS_DEPS_TYPE_BASIC 1
66#define STATS_MCV_MAGIC 0xE1A651C2
67#define STATS_MCV_TYPE_BASIC 1
70#define STATS_MCVLIST_MAX_ITEMS MAX_STATISTICS_TARGET
Datum idx(PG_FUNCTION_ARGS)
#define FLEXIBLE_ARRAY_MEMBER
bool has_stats_of_kind(List *stats, char requiredkind)
struct MVNDistinct MVNDistinct
MVDependencies * statext_dependencies_load(Oid mvoid, bool inh)
MCVList * statext_mcv_load(Oid mvoid, bool inh)
StatisticExtInfo * choose_best_statistics(List *stats, char requiredkind, bool inh, Bitmapset **clause_attnums, List **clause_exprs, int nclauses)
int ComputeExtStatisticsRows(Relation onerel, int natts, VacAttrStats **vacattrstats)
struct MVNDistinctItem MVNDistinctItem
struct MVDependencies MVDependencies
#define STATS_MAX_DIMENSIONS
MVNDistinct * statext_ndistinct_load(Oid mvoid, bool inh)
bool statext_is_kind_built(HeapTuple htup, char type)
struct MVDependency MVDependency
void BuildRelationExtStatistics(Relation onerel, bool inh, double totalrows, int numrows, HeapTuple *rows, int natts, VacAttrStats **vacattrstats)
Selectivity statext_clauselist_selectivity(PlannerInfo *root, List *clauses, int varRelid, JoinType jointype, SpecialJoinInfo *sjinfo, RelOptInfo *rel, Bitmapset **estimatedclauses, bool is_or)
Selectivity dependencies_clauselist_selectivity(PlannerInfo *root, List *clauses, int varRelid, JoinType jointype, SpecialJoinInfo *sjinfo, RelOptInfo *rel, Bitmapset **estimatedclauses)
HeapTuple statext_expressions_load(Oid stxoid, bool inh, int idx)
MCVItem items[FLEXIBLE_ARRAY_MEMBER]
Oid types[STATS_MAX_DIMENSIONS]
MVDependency * deps[FLEXIBLE_ARRAY_MEMBER]
AttrNumber attributes[FLEXIBLE_ARRAY_MEMBER]
MVNDistinctItem items[FLEXIBLE_ARRAY_MEMBER]