diff options
| author | Tom Lane | 2005-07-23 21:05:48 +0000 |
|---|---|---|
| committer | Tom Lane | 2005-07-23 21:05:48 +0000 |
| commit | d007a95055b9b649b74b5d25aa4d2b46f3eca21c (patch) | |
| tree | e726c049f96af578181432ae4da176cf3cbcb970 /src/include/optimizer | |
| parent | 9af9d674c61ca1c2e26d7a9295d5b1bcc8cabb60 (diff) | |
Simple constraint exclusion. For now, only child tables of inheritance
scans are candidates for exclusion; this should be fixed eventually.
Simon Riggs, with some help from Tom Lane.
Diffstat (limited to 'src/include/optimizer')
| -rw-r--r-- | src/include/optimizer/cost.h | 3 | ||||
| -rw-r--r-- | src/include/optimizer/plancat.h | 4 | ||||
| -rw-r--r-- | src/include/optimizer/predtest.h | 4 |
3 files changed, 8 insertions, 3 deletions
diff --git a/src/include/optimizer/cost.h b/src/include/optimizer/cost.h index 5b6d2824253..a6988e45991 100644 --- a/src/include/optimizer/cost.h +++ b/src/include/optimizer/cost.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/optimizer/cost.h,v 1.68 2005/06/05 22:32:58 tgl Exp $ + * $PostgreSQL: pgsql/src/include/optimizer/cost.h,v 1.69 2005/07/23 21:05:48 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -49,6 +49,7 @@ extern bool enable_hashagg; extern bool enable_nestloop; extern bool enable_mergejoin; extern bool enable_hashjoin; +extern bool enable_constraint_exclusion; extern double clamp_row_est(double nrows); extern void cost_seqscan(Path *path, PlannerInfo *root, RelOptInfo *baserel); diff --git a/src/include/optimizer/plancat.h b/src/include/optimizer/plancat.h index f8ecd36110d..8a4c1e4941e 100644 --- a/src/include/optimizer/plancat.h +++ b/src/include/optimizer/plancat.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/optimizer/plancat.h,v 1.36 2005/06/05 22:32:58 tgl Exp $ + * $PostgreSQL: pgsql/src/include/optimizer/plancat.h,v 1.37 2005/07/23 21:05:48 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -19,6 +19,8 @@ extern void get_relation_info(Oid relationObjectId, RelOptInfo *rel); +extern List *get_relation_constraints(Oid relationObjectId, RelOptInfo *rel); + extern List *build_physical_tlist(PlannerInfo *root, RelOptInfo *rel); extern List *find_inheritance_children(Oid inhparent); diff --git a/src/include/optimizer/predtest.h b/src/include/optimizer/predtest.h index cfa58f650a1..0fc0d0f4476 100644 --- a/src/include/optimizer/predtest.h +++ b/src/include/optimizer/predtest.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/optimizer/predtest.h,v 1.1 2005/06/10 22:25:37 tgl Exp $ + * $PostgreSQL: pgsql/src/include/optimizer/predtest.h,v 1.2 2005/07/23 21:05:48 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -19,5 +19,7 @@ extern bool predicate_implied_by(List *predicate_list, List *restrictinfo_list); +extern bool predicate_refuted_by(List *predicate_list, + List *restrictinfo_list); #endif /* PREDTEST_H */ |
