-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[fix](nereids) fix LogicalRepeat compute equalset (#47737)
### What problem does this PR solve? Issue Number: close #xxx Related PR: #xxx Problem Summary: This PR addresses an issue where LogicalRepeat should not propagate equalset because, in scenarios involving group by cube(a, b) with a = b, LogicalRepeat generates four rows (e.g., when a = b = 3, the rows are (3,3), (3,null), (null,3), and (null,null)), which breaks the equalset relationship a = b. To resolve this, the equalset slots are now retained only when they are part of the common set of LogicalRepeat's group by keys. This ensures the integrity of equalset is maintained during group by cube operations, preventing incorrect query results.
- Loading branch information
1 parent
5a7454e
commit 2dd9689
Showing
5 changed files
with
41 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,3 +9,12 @@ | |
1 | ||
1 | ||
|
||
-- !grouping_equalset -- | ||
1 | ||
1 | ||
1 | ||
1 | ||
|
||
-- !grouping_equalset_can_eliminate -- | ||
2 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters