- Notifications
You must be signed in to change notification settings - Fork4.9k
Commit61444bf
committed
Allow to push down clauses from HAVING to WHERE when grouping sets are used.
Previously we disallowed pushing down quals to WHERE in the presence ofgrouping sets. That's overly restrictive.We now instead copy quals to WHERE if applicable, leaving theone in HAVING in place. That's because, at that stage of the planningprocess, it's nontrivial to determine if it's safe to remove the one inHAVING.Author: Andrew GierthDiscussion: 874mkt3l59.fsf@news-spur.riddles.org.ukBackpatch: 9.5, where grouping sets were introduced. This isn't exactly a bugfix, but it seems better to keep the branches in sync at this point.1 parente6d8cb7 commit61444bf
1 file changed
+2
-3
lines changedLines changed: 2 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
570 | 570 |
| |
571 | 571 |
| |
572 | 572 |
| |
573 |
| - | |
574 |
| - | |
| 573 | + | |
575 | 574 |
| |
576 | 575 |
| |
577 | 576 |
| |
578 | 577 |
| |
579 |
| - | |
| 578 | + | |
580 | 579 |
| |
581 | 580 |
| |
582 | 581 |
| |
|
0 commit comments
Comments
(0)