From f41803bb39bc2949db200116a609fd242d0ec221 Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Sat, 20 Jan 2007 20:45:41 +0000 Subject: Refactor planner's pathkeys data structure to create a separate, explicit representation of equivalence classes of variables. This is an extensive rewrite, but it brings a number of benefits: * planner no longer fails in the presence of "incomplete" operator families that don't offer operators for every possible combination of datatypes. * avoid generating and then discarding redundant equality clauses. * remove bogus assumption that derived equalities always use operators named "=". * mergejoins can work with a variety of sort orders (e.g., descending) now, instead of tying each mergejoinable operator to exactly one sort order. * better recognition of redundant sort columns. * can make use of equalities appearing underneath an outer join. --- src/backend/optimizer/prep/prepunion.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/backend/optimizer/prep/prepunion.c') diff --git a/src/backend/optimizer/prep/prepunion.c b/src/backend/optimizer/prep/prepunion.c index cd7952aefde..ec93b0dad07 100644 --- a/src/backend/optimizer/prep/prepunion.c +++ b/src/backend/optimizer/prep/prepunion.c @@ -22,7 +22,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/optimizer/prep/prepunion.c,v 1.135 2007/01/05 22:19:32 momjian Exp $ + * $PostgreSQL: pgsql/src/backend/optimizer/prep/prepunion.c,v 1.136 2007/01/20 20:45:39 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -1195,10 +1195,8 @@ adjust_appendrel_attrs_mutator(Node *node, AppendRelInfo *context) */ newinfo->eval_cost.startup = -1; newinfo->this_selec = -1; - newinfo->left_pathkey = NIL; - newinfo->right_pathkey = NIL; - newinfo->left_mergescansel = -1; - newinfo->right_mergescansel = -1; + newinfo->left_ec = NULL; + newinfo->right_ec = NULL; newinfo->left_bucketsize = -1; newinfo->right_bucketsize = -1; -- cgit v1.2.3