Department of second thoughts: can't reorder merge-join clauses.
authorTom Lane
Wed, 27 Aug 2003 12:44:12 +0000 (12:44 +0000)
committerTom Lane
Wed, 27 Aug 2003 12:44:12 +0000 (12:44 +0000)
src/backend/optimizer/plan/createplan.c

index fb5040c94ce603d49c340210edee55e1e36280b1..e3ad5bc65544a19957f36fbedca23dfacc9ed8e1 100644 (file)
@@ -10,7 +10,7 @@
  *
  *
  * IDENTIFICATION
- *   $Header: /cvsroot/pgsql/src/backend/optimizer/plan/createplan.c,v 1.156 2003/08/26 22:56:51 tgl Exp $
+ *   $Header: /cvsroot/pgsql/src/backend/optimizer/plan/createplan.c,v 1.157 2003/08/27 12:44:12 tgl Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -1000,9 +1000,9 @@ create_mergejoin_plan(Query *root,
                         best_path->jpath.outerjoinpath->parent->relids);
 
    /* Sort clauses into best execution order */
+   /* NB: do NOT reorder the mergeclauses */
    joinclauses = order_qual_clauses(root, joinclauses);
    otherclauses = order_qual_clauses(root, otherclauses);
-   mergeclauses = order_qual_clauses(root, mergeclauses);
 
    /*
     * Create explicit sort nodes for the outer and inner join paths if