You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 20, 2023. It is now read-only.
* Fix correlated subquery optimizer rules
Part of RewritePullFilterThroughAggregation and
DependentSingleJoinToInnerJoin rules adds a group by
column to the aggregation from one of the sides of the predicate.
When selecting a column we need to make sure that the column is at
the same depth as the aggregation or deeper. If the group by column
is part of the outer query and the aggregation part of the inner
query, then the aggregation has no way of accessing the column. A
higher value for depth means deeper in the querer and a lower value
for depth means more shallow in the query. The current code was
always setting the column from the left side of the predicate as the
group by column. This was sometimes causing the group by column to
be more shallow than the aggregation itself which caused the query
to error out.
Fixes#1404
* Add comments
* Fix comments and variable naming
* Fix comments
* Remove dead code from DependentSingleJoinToInnerJoin
* Revert "Remove dead code from DependentSingleJoinToInnerJoin"
This reverts commit d1255a3.
* Extract common code from nested predicate rules
* Respond to PR comments
Co-authored-by: Wan Shen Lim <[email protected]>
Co-authored-by: Matt Butrovich <[email protected]>
0 commit comments