Alex Behm has posted comments on this change. Change subject: IMPALA-4792: Fix number of distinct values for a CASE with constant outputs ......................................................................
Patch Set 6: (5 comments) I'm pretty happy with this change minus the remaining nits. http://gerrit.cloudera.org:8080/#/c/5768/6/fe/src/main/java/org/apache/impala/analysis/CaseExpr.java File fe/src/main/java/org/apache/impala/analysis/CaseExpr.java: Line 385: // sum the number of constants with the maximum distinct value for the ... sum the number of distinct constants with the maximum NDV for the non-constants. http://gerrit.cloudera.org:8080/#/c/5768/6/fe/src/test/java/org/apache/impala/analysis/ExprNdvTest.java File fe/src/test/java/org/apache/impala/analysis/ExprNdvTest.java: Line 27: * Tests computeNumDistinctValues estimates for Exprs computeNumDistinctValues() Line 44: public void VerifyNdv(String stmtStr, long expectedNdv) can we make this VerifyNdvStmt() or something so that we can use VerifyNdv() for the common case of writing tests? Line 93: // functional.tinytable (tiny) does not move this into the function comment of VerifyNdvTwoTable() Line 96: VerifyNdvTwoTable("case when a.id = 1 then 'yes' " + remove whitespace -- To view, visit http://gerrit.cloudera.org:8080/5768 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: I21dbdaad8452b7e58c477612b47847dccd9d98d2 Gerrit-PatchSet: 6 Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-Owner: Joe McDonnell <[email protected]> Gerrit-Reviewer: Alex Behm <[email protected]> Gerrit-Reviewer: Joe McDonnell <[email protected]> Gerrit-Reviewer: Marcel Kornacker <[email protected]> Gerrit-HasComments: Yes
