]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
In a nestloop inner indexscan, it's OK to use pushed-down baserestrictinfo
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 6 Dec 2005 16:50:55 +0000 (16:50 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 6 Dec 2005 16:50:55 +0000 (16:50 +0000)
clauses even if it's an outer join.  This is a corner case since such
clauses could only arise from weird OUTER JOIN ON conditions, but worth
fixing.  Per example from Ron at cheapcomplexdevices.com.

src/backend/optimizer/path/indxpath.c

index 5680cbbc6e3bef677f9277c99859da0e8cd39daf..dc26fc40cac8953a8c620fdf68ef541662b0e758 100644 (file)
@@ -9,7 +9,7 @@
  *
  *
  * IDENTIFICATION
- *       $PostgreSQL: pgsql/src/backend/optimizer/path/indxpath.c,v 1.167.4.2 2005/04/20 21:48:12 tgl Exp $
+ *       $PostgreSQL: pgsql/src/backend/optimizer/path/indxpath.c,v 1.167.4.3 2005/12/06 16:50:55 tgl Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -332,10 +332,6 @@ group_clauses_by_indexkey_for_join(Query *root,
                {
                        RestrictInfo *rinfo = (RestrictInfo *) lfirst(l);
 
-                       /* Can't use pushed-down clauses in outer join */
-                       if (isouterjoin && rinfo->is_pushed_down)
-                               continue;
-
                        if (match_clause_to_indexcol(rel,
                                                                                 index,
                                                                                 indexcol,