-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-22141][SQL] Propagate empty relation before checking Cartesian products #19362
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -124,8 +124,6 @@ abstract class Optimizer(sessionCatalog: SessionCatalog) | |
| SimplifyCreateMapOps, | ||
| CombineConcats) ++ | ||
| extendedOperatorOptimizationRules: _*) :: | ||
| Batch("Check Cartesian Products", Once, | ||
| CheckCartesianProducts) :: | ||
| Batch("Join Reorder", Once, | ||
| CostBasedJoinReorder) :: | ||
| Batch("Decimal Optimizations", fixedPoint, | ||
|
|
@@ -136,6 +134,8 @@ abstract class Optimizer(sessionCatalog: SessionCatalog) | |
| Batch("LocalRelation", fixedPoint, | ||
| ConvertToLocalRelation, | ||
| PropagateEmptyRelation) :: | ||
| Batch("Check Cartesian Products", Once, | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. we should also add a comment here about the positioning ...
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Make sense. The PR is merged, what should I do now..
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Create a follow-up PR
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @gatorsmile I see, thanks! |
||
| CheckCartesianProducts) :: | ||
| Batch("OptimizeCodegen", Once, | ||
| OptimizeCodegen) :: | ||
| Batch("RewriteSubquery", Once, | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the comment of
CheckCartesianProductsshould also be updated and add this constrain.