1 /*-------------------------------------------------------------------------
4 * prototypes for plancat.c.
7 * Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
8 * Portions Copyright (c) 1994, Regents of the University of California
10 * $PostgreSQL: pgsql/src/include/optimizer/plancat.h,v 1.54 2009/06/11 14:49:11 momjian Exp $
12 *-------------------------------------------------------------------------
17 #include "nodes/relation.h"
18 #include "utils/relcache.h"
20 /* Hook for plugins to get control in get_relation_info() */
21 typedef void (*get_relation_info_hook_type) (PlannerInfo *root,
25 extern PGDLLIMPORT get_relation_info_hook_type get_relation_info_hook;
28 extern void get_relation_info(PlannerInfo *root, Oid relationObjectId,
29 bool inhparent, RelOptInfo *rel);
31 extern void estimate_rel_size(Relation rel, int32 *attr_widths,
32 BlockNumber *pages, double *tuples);
34 extern bool relation_excluded_by_constraints(PlannerInfo *root,
35 RelOptInfo *rel, RangeTblEntry *rte);
37 extern List *build_physical_tlist(PlannerInfo *root, RelOptInfo *rel);
39 extern bool has_unique_index(RelOptInfo *rel, AttrNumber attno);
41 extern Selectivity restriction_selectivity(PlannerInfo *root,
46 extern Selectivity join_selectivity(PlannerInfo *root,
50 SpecialJoinInfo *sjinfo);
52 #endif /* PLANCAT_H */