Riza Suminto has posted comments on this change. ( http://gerrit.cloudera.org:8080/21688 )
Change subject: IMPALA-13262: Do not always migrate inferred predicates into inline view ...................................................................... Patch Set 1: (2 comments) Thank you for looking into this. http://gerrit.cloudera.org:8080/#/c/21688/1/fe/src/main/java/org/apache/impala/planner/SingleNodePlanner.java File fe/src/main/java/org/apache/impala/planner/SingleNodePlanner.java: http://gerrit.cloudera.org:8080/#/c/21688/1/fe/src/main/java/org/apache/impala/planner/SingleNodePlanner.java@1527 PS1, Line 1527: removeDisqualifyingInferredPreds(inlineViewRef.getAnalyzer(), : !canMigrateConjuncts(inlineViewRef), viewPredicates); This is the only callsite to removeDisqualifyingInferredPreds(). The function parameter can be simplified to accept InlineViewRef and List<Expr>. The !canMigrateConjuncts() check then can be done inside removeDisqualifyingInferredPreds(). http://gerrit.cloudera.org:8080/#/c/21688/1/testdata/workloads/functional-query/queries/QueryTest/inline-view.test File testdata/workloads/functional-query/queries/QueryTest/inline-view.test: http://gerrit.cloudera.org:8080/#/c/21688/1/testdata/workloads/functional-query/queries/QueryTest/inline-view.test@597 PS1, Line 597: # IMPALA-13262: Do not migrate an inferred predicate into an inline view if both sides of Please add these two test cases for output comparison: SELECT * FROM ( SELECT year, id, int_col, ROW_NUMBER() over(PARTITION BY year ORDER BY id DESC) rn FROM functional.alltypes ) iv WHERE rn = 3650; SELECT * FROM ( SELECT year, id, int_col, ROW_NUMBER() over(PARTITION BY year ORDER BY id DESC) rn FROM functional.alltypes WHERE id = int_col ) iv WHERE rn = 3650; -- To view, visit http://gerrit.cloudera.org:8080/21688 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I6e2632b3b1a140ae0104ceba4e2f474ac1bbcda1 Gerrit-Change-Number: 21688 Gerrit-PatchSet: 1 Gerrit-Owner: Fang-Yu Rao <fangyu....@cloudera.com> Gerrit-Reviewer: Aman Sinha <amsi...@cloudera.com> Gerrit-Reviewer: Fang-Yu Rao <fangyu....@cloudera.com> Gerrit-Reviewer: Impala Public Jenkins <impala-public-jenk...@cloudera.com> Gerrit-Reviewer: Michael Smith <michael.sm...@cloudera.com> Gerrit-Reviewer: Quanlong Huang <huangquanl...@gmail.com> Gerrit-Reviewer: Riza Suminto <riza.sumi...@cloudera.com> Gerrit-Comment-Date: Mon, 19 Aug 2024 23:00:47 +0000 Gerrit-HasComments: Yes