pgsql: Remove bogus code to apply PathTargets to partial paths.

From: Robert Haas <rhaas(at)postgresql(dot)org>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Remove bogus code to apply PathTargets to partial paths.
Date: 2016-06-03 18:31:15
Message-ID: E1b8tsJ-0006lZ-1k@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Remove bogus code to apply PathTargets to partial paths.

The partial paths that get modified may already have been used as
part of a GatherPath which appears in the path list, so modifying
them is not a good idea at this stage - especially because this
code has no check that the PathTarget is in fact parallel-safe.

When partial aggregation is being performed, this is actually
harmless because we'll end up replacing the pathtargets here with
the correct ones within create_grouping_paths(). But if we've got
a query tree containing only scan/join operations then this can
result in incorrectly pushing down parallel-restricted target
list entries. If those are, for example, references to subqueries,
that can crash the server; but it's wrong in any event.

Amit Kapila

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/04ae11f62e643e07c411c4935ea6af46cb112aa9

Modified Files
--------------
src/backend/optimizer/plan/planner.c | 13 -------------
1 file changed, 13 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2016-06-03 19:15:02 pgsql: Mark read/write expanded values as read-only in ExecProject().
Previous Message Robert Haas 2016-06-03 18:08:37 pgsql: Mark PostmasterPid as PGDLLIMPORT.