Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Check if plan is valid before applying any optimizers. If plan is invalid then some optimizer may throw very misleading exception. For example please see the #7773 issue, where access control error was throw, but it was caused unexpected subquery expression within an plan node tree. No the query from #7773 would throw something like below: java.lang.IllegalStateException: Unexpected subquery expression in logical plan: (SELECT 1 ) at com.facebook.presto.sql.planner.sanity.NoSubqueryExpressionLeftChecker$1.visitSubqueryExpression(NoSubqueryExpressionLeftChecker.java:43) ... com.facebook.presto.sql.planner.sanity.PlanSanityChecker.validateIntermediatePlan(PlanSanityChecker.java:54) ...
- Loading branch information
Showing
2 changed files
with
36 additions
and
14 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