diff options
| author | Tom Lane | 2001-02-16 00:03:08 +0000 |
|---|---|---|
| committer | Tom Lane | 2001-02-16 00:03:08 +0000 |
| commit | b29f68f611e26377306a9ba2210a589b472c8544 (patch) | |
| tree | 00a057a7682b2a727a9445b753af10dde172a3d4 /src/include/optimizer | |
| parent | ca71c6619086ac3b6e3787c2826363faeab02ac9 (diff) | |
Take OUTER JOIN semantics into account when estimating the size of join
relations. It's not very bright, but at least it now knows that
A LEFT JOIN B must produce at least as many rows as are in A ...
Diffstat (limited to 'src/include/optimizer')
| -rw-r--r-- | src/include/optimizer/cost.h | 3 | ||||
| -rw-r--r-- | src/include/optimizer/pathnode.h | 10 |
2 files changed, 8 insertions, 5 deletions
diff --git a/src/include/optimizer/cost.h b/src/include/optimizer/cost.h index c6dfcac39c9..5caa576f0c0 100644 --- a/src/include/optimizer/cost.h +++ b/src/include/optimizer/cost.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $Id: cost.h,v 1.37 2001/01/24 19:43:26 momjian Exp $ + * $Id: cost.h,v 1.38 2001/02/16 00:03:05 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -70,6 +70,7 @@ extern void set_baserel_size_estimates(Query *root, RelOptInfo *rel); extern void set_joinrel_size_estimates(Query *root, RelOptInfo *rel, RelOptInfo *outer_rel, RelOptInfo *inner_rel, + JoinType jointype, List *restrictlist); /* diff --git a/src/include/optimizer/pathnode.h b/src/include/optimizer/pathnode.h index b4e239aa8f7..7e000034761 100644 --- a/src/include/optimizer/pathnode.h +++ b/src/include/optimizer/pathnode.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $Id: pathnode.h,v 1.33 2001/01/24 19:43:26 momjian Exp $ + * $Id: pathnode.h,v 1.34 2001/02/16 00:03:06 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -66,8 +66,10 @@ extern HashPath *create_hashjoin_path(RelOptInfo *joinrel, */ extern RelOptInfo *get_base_rel(Query *root, int relid); extern RelOptInfo *make_base_rel(Query *root, int relid); -extern RelOptInfo *get_join_rel(Query *root, RelOptInfo *outer_rel, - RelOptInfo *inner_rel, - List **restrictlist_ptr); +extern RelOptInfo *get_join_rel(Query *root, + RelOptInfo *outer_rel, + RelOptInfo *inner_rel, + JoinType jointype, + List **restrictlist_ptr); #endif /* PATHNODE_H */ |
