diff options
author | Andrew Gierth | 2019-06-30 22:49:29 +0000 |
---|---|---|
committer | Andrew Gierth | 2019-06-30 22:49:29 +0000 |
commit | 793eb94e31387738c72a8d7d702a6aecc9c5edee (patch) | |
tree | ac11bb0b376cf01d8b9164dbdb1ba822ebd5897d /doc/src | |
parent | 0908c5ecf0833b020b0d95183804ebc22bb6ea6c (diff) |
Repair logic for reordering grouping sets optimization.
The logic in reorder_grouping_sets to order grouping set elements to
match a pre-specified sort ordering was defective, resulting in
unnecessary sort nodes (though the query output would still be
correct). Repair, simplifying the code a little, and add a test.
Per report from Richard Guo, though I didn't use their patch. Original
bug seems to have been my fault.
Backpatch back to 9.5 where grouping sets were introduced.
Discussion: https://postgr.es/m/CAN_9JTzyjGcUjiBHxLsgqfk7PkdLGXiM=pwM+=ph2LsWw0WO1A@mail.gmail.com
Diffstat (limited to 'doc/src')
0 files changed, 0 insertions, 0 deletions