forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitf120b61
committed
plpgsql: Don't generate parallel plans for RETURN QUERY.
Commit7aea8e4 allowed a parallelplan to be generated when for a RETURN QUERY or RETURN QUERY EXECUTEstatement in a PL/pgsql block, but that's a bad idea because plplgsqlasks the executor for 50 rows at a time. That means that we'll alwaysbe running serially a plan that was intended for parallel execution,which is not a good idea. Fix by not requesting a parallel plan fromthe outset.Per discussion, back-patch to 9.6. There is a slight risk that, dueto optimizer error, somebody could have a case where the parallel planexecuted serially is actually faster than the supposedly-best serialplan, but the consensus seems to be that that's not sufficientjustification for leaving 9.6 unpatched.Discussion:http://postgr.es/m/CA+TgmoZ_ZuH+auEeeWnmtorPsgc_SmP+XWbDsJ+cWvWBSjNwDQ@mail.gmail.comDiscussion:http://postgr.es/m/CA+TgmobXEhvHbJtWDuPZM9bVSLiTj-kShxQJ2uM5GPDze9fRYA@mail.gmail.com1 parent857ee8e commitf120b61
1 file changed
+2
-2
lines changedLines changed: 2 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
3023 | 3023 |
| |
3024 | 3024 |
| |
3025 | 3025 |
| |
3026 |
| - | |
| 3026 | + | |
3027 | 3027 |
| |
3028 | 3028 |
| |
3029 | 3029 |
| |
3030 | 3030 |
| |
3031 | 3031 |
| |
3032 | 3032 |
| |
3033 | 3033 |
| |
3034 |
| - | |
| 3034 | + | |
3035 | 3035 |
| |
3036 | 3036 |
| |
3037 | 3037 |
| |
|
0 commit comments
Comments
(0)