Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit4756ff3

Browse files
committed
Put back copyObject() call I removed in a fit of brain fade. This one
is still needed despite cleanups in setrefs.c, because the point is tolet the inserted Result node compute a different tlist than its inputnode does. Per example from Jeremy Drake.
1 parent7395c76 commit4756ff3

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

‎src/backend/optimizer/plan/createplan.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
*
1111
*
1212
* IDENTIFICATION
13-
* $PostgreSQL: pgsql/src/backend/optimizer/plan/createplan.c,v 1.226 2007/02/22 22:00:24 tgl Exp $
13+
* $PostgreSQL: pgsql/src/backend/optimizer/plan/createplan.c,v 1.227 2007/02/25 17:44:01 tgl Exp $
1414
*
1515
*-------------------------------------------------------------------------
1616
*/
@@ -2740,7 +2740,11 @@ make_sort_from_pathkeys(PlannerInfo *root, Plan *lefttree, List *pathkeys)
27402740
* Do we need to insert a Result node?
27412741
*/
27422742
if (!is_projection_capable_plan(lefttree))
2743+
{
2744+
/* copy needed so we don't modify input's tlist below */
2745+
tlist=copyObject(tlist);
27432746
lefttree= (Plan*)make_result(root,tlist,NULL,lefttree);
2747+
}
27442748

27452749
/*
27462750
* Add resjunk entry to input's tlist

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp