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

Commit01f08cb

Browse files
committed
Fix test for subplans in force-parallel mode.
We mustn't force parallel mode if the query has any subplans, sinceExecSerializePlan doesn't transmit them to workers. Testingtop_plan->initPlan is inadequate because (1) there might be initPlansattached to lower plan nodes, and (2) non-initPlan subplans don'twork either. There's certainly room for improvement in thoserestrictions, but for the moment that's what we've got.Amit Kapila, per report from Andreas SeltenreichDiscussion: <8737im6pmh.fsf@credativ.de>
1 parent90f8b4b commit01f08cb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -327,11 +327,11 @@ standard_planner(Query *parse, int cursorOptions, ParamListInfo boundParams)
327327
* actually a safe thing to do. (Note: we assume adding a Material node
328328
* above did not change the parallel safety of the plan, so we can still
329329
* rely on best_path->parallel_safe. However, that flag doesn't account
330-
* forinitPlans, whichrender the plan parallel-unsafe.)
330+
* forsubplans, whichwe are unable to transmit to workers presently.)
331331
*/
332332
if (force_parallel_mode!=FORCE_PARALLEL_OFF&&
333333
best_path->parallel_safe&&
334-
top_plan->initPlan==NIL)
334+
glob->subplans==NIL)
335335
{
336336
Gather*gather=makeNode(Gather);
337337

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp