1996-07-09 08:22:35 +02:00
|
|
|
/*-------------------------------------------------------------------------
|
|
|
|
*
|
1999-02-14 00:22:53 +01:00
|
|
|
* plancat.h
|
1997-09-07 07:04:48 +02:00
|
|
|
* prototypes for plancat.c.
|
1996-07-09 08:22:35 +02:00
|
|
|
*
|
|
|
|
*
|
2007-01-05 23:20:05 +01:00
|
|
|
* Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group
|
2000-01-26 06:58:53 +01:00
|
|
|
* Portions Copyright (c) 1994, Regents of the University of California
|
1996-07-09 08:22:35 +02:00
|
|
|
*
|
2007-05-25 19:54:25 +02:00
|
|
|
* $PostgreSQL: pgsql/src/include/optimizer/plancat.h,v 1.44 2007/05/25 17:54:25 tgl Exp $
|
1996-07-09 08:22:35 +02:00
|
|
|
*
|
|
|
|
*-------------------------------------------------------------------------
|
|
|
|
*/
|
|
|
|
#ifndef PLANCAT_H
|
|
|
|
#define PLANCAT_H
|
|
|
|
|
2000-01-09 01:26:47 +01:00
|
|
|
#include "nodes/relation.h"
|
1996-07-09 08:22:35 +02:00
|
|
|
|
2007-05-25 19:54:25 +02:00
|
|
|
/* Hook for plugins to get control in get_relation_info() */
|
|
|
|
typedef void (*get_relation_info_hook_type) (PlannerInfo *root,
|
|
|
|
Oid relationObjectId,
|
|
|
|
bool inhparent,
|
|
|
|
RelOptInfo *rel);
|
|
|
|
extern DLLIMPORT get_relation_info_hook_type get_relation_info_hook;
|
|
|
|
|
1999-11-22 00:25:47 +01:00
|
|
|
|
2006-09-20 00:49:53 +02:00
|
|
|
extern void get_relation_info(PlannerInfo *root, Oid relationObjectId,
|
2006-10-04 02:30:14 +02:00
|
|
|
bool inhparent, RelOptInfo *rel);
|
1996-07-09 08:22:35 +02:00
|
|
|
|
2006-02-05 00:03:20 +01:00
|
|
|
extern bool relation_excluded_by_constraints(RelOptInfo *rel,
|
2006-10-04 02:30:14 +02:00
|
|
|
RangeTblEntry *rte);
|
2005-07-23 23:05:48 +02:00
|
|
|
|
2005-06-06 00:32:58 +02:00
|
|
|
extern List *build_physical_tlist(PlannerInfo *root, RelOptInfo *rel);
|
2003-06-30 01:05:05 +02:00
|
|
|
|
2000-01-09 01:26:47 +01:00
|
|
|
extern List *find_inheritance_children(Oid inhparent);
|
|
|
|
|
2000-06-09 05:17:13 +02:00
|
|
|
extern bool has_subclass(Oid relationId);
|
|
|
|
|
2001-05-20 22:28:20 +02:00
|
|
|
extern bool has_unique_index(RelOptInfo *rel, AttrNumber attno);
|
1996-07-09 08:22:35 +02:00
|
|
|
|
2005-06-06 00:32:58 +02:00
|
|
|
extern Selectivity restriction_selectivity(PlannerInfo *root,
|
2001-10-25 07:50:21 +02:00
|
|
|
Oid operator,
|
|
|
|
List *args,
|
|
|
|
int varRelid);
|
2001-05-20 22:28:20 +02:00
|
|
|
|
2005-06-06 00:32:58 +02:00
|
|
|
extern Selectivity join_selectivity(PlannerInfo *root,
|
2003-08-04 02:43:34 +02:00
|
|
|
Oid operator,
|
|
|
|
List *args,
|
|
|
|
JoinType jointype);
|
2001-10-28 07:26:15 +01:00
|
|
|
|
2001-11-05 18:46:40 +01:00
|
|
|
#endif /* PLANCAT_H */
|