forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit420c166
committed
Fix failure to mark all aggregates with appropriate transtype.
In commit915b703 I gave get_agg_clause_costs() the responsibility ofmarking Aggref nodes with the appropriate aggtranstype. I failed to noticethat where it was being called from, it might see only a subset of theAggref nodes that were in the original targetlist. Specifically, if thereare duplicate aggregate calls in the tlist, either make_sort_input_targetor make_window_input_target might put just a single instance into thegrouping_target, and then only that instance would get marked. Fix bymoving the call back into grouping_planner(), before we start buildingassorted PathTargets from the query tlist. Per report from Stefan Huehner.Report: <20160702131056.GD3165@huehner.biz>1 parentb54f7a9 commit420c166
3 files changed
+65
-21
lines changedLines changed: 33 additions & 21 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
114 | 114 |
| |
115 | 115 |
| |
116 | 116 |
| |
| 117 | + | |
117 | 118 |
| |
118 | 119 |
| |
119 | 120 |
| |
| |||
1499 | 1500 |
| |
1500 | 1501 |
| |
1501 | 1502 |
| |
| 1503 | + | |
1502 | 1504 |
| |
1503 | 1505 |
| |
1504 | 1506 |
| |
| |||
1623 | 1625 |
| |
1624 | 1626 |
| |
1625 | 1627 |
| |
| 1628 | + | |
| 1629 | + | |
| 1630 | + | |
| 1631 | + | |
| 1632 | + | |
| 1633 | + | |
| 1634 | + | |
| 1635 | + | |
| 1636 | + | |
| 1637 | + | |
| 1638 | + | |
| 1639 | + | |
| 1640 | + | |
| 1641 | + | |
| 1642 | + | |
| 1643 | + | |
| 1644 | + | |
| 1645 | + | |
| 1646 | + | |
| 1647 | + | |
| 1648 | + | |
| 1649 | + | |
1626 | 1650 |
| |
1627 | 1651 |
| |
1628 | 1652 |
| |
| |||
1822 | 1846 |
| |
1823 | 1847 |
| |
1824 | 1848 |
| |
| 1849 | + | |
1825 | 1850 |
| |
1826 | 1851 |
| |
1827 | 1852 |
| |
| |||
3244 | 3269 |
| |
3245 | 3270 |
| |
3246 | 3271 |
| |
| 3272 | + | |
3247 | 3273 |
| |
3248 | 3274 |
| |
3249 | 3275 |
| |
| |||
3260 | 3286 |
| |
3261 | 3287 |
| |
3262 | 3288 |
| |
| 3289 | + | |
3263 | 3290 |
| |
3264 | 3291 |
| |
3265 | 3292 |
| |
3266 | 3293 |
| |
3267 | 3294 |
| |
3268 | 3295 |
| |
3269 | 3296 |
| |
3270 |
| - | |
3271 | 3297 |
| |
3272 | 3298 |
| |
3273 | 3299 |
| |
| |||
3364 | 3390 |
| |
3365 | 3391 |
| |
3366 | 3392 |
| |
3367 |
| - | |
3368 |
| - | |
3369 |
| - | |
3370 |
| - | |
3371 |
| - | |
3372 |
| - | |
3373 |
| - | |
3374 |
| - | |
3375 |
| - | |
3376 |
| - | |
3377 |
| - | |
3378 |
| - | |
3379 |
| - | |
3380 |
| - | |
3381 | 3393 |
| |
3382 | 3394 |
| |
3383 | 3395 |
| |
| |||
3414 | 3426 |
| |
3415 | 3427 |
| |
3416 | 3428 |
| |
3417 |
| - | |
| 3429 | + | |
3418 | 3430 |
| |
3419 | 3431 |
| |
3420 | 3432 |
| |
| |||
3446 | 3458 |
| |
3447 | 3459 |
| |
3448 | 3460 |
| |
3449 |
| - | |
| 3461 | + | |
3450 | 3462 |
| |
3451 | 3463 |
| |
3452 | 3464 |
| |
| |||
3627 | 3639 |
| |
3628 | 3640 |
| |
3629 | 3641 |
| |
3630 |
| - | |
| 3642 | + | |
3631 | 3643 |
| |
3632 | 3644 |
| |
3633 | 3645 |
| |
| |||
3645 | 3657 |
| |
3646 | 3658 |
| |
3647 | 3659 |
| |
3648 |
| - | |
| 3660 | + | |
3649 | 3661 |
| |
3650 | 3662 |
| |
3651 | 3663 |
| |
| |||
3727 | 3739 |
| |
3728 | 3740 |
| |
3729 | 3741 |
| |
3730 |
| - | |
| 3742 | + | |
3731 | 3743 |
| |
3732 | 3744 |
| |
3733 | 3745 |
| |
| |||
3751 | 3763 |
| |
3752 | 3764 |
| |
3753 | 3765 |
| |
3754 |
| - | |
| 3766 | + | |
3755 | 3767 |
| |
3756 | 3768 |
| |
3757 | 3769 |
| |
|
Lines changed: 24 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
296 | 296 |
| |
297 | 297 |
| |
298 | 298 |
| |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + |
Lines changed: 8 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
91 | 91 |
| |
92 | 92 |
| |
93 | 93 |
| |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + |
0 commit comments
Comments
(0)