impala-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alex Behm (Code Review)" <ger...@cloudera.org>
Subject [Impala-ASF-CR] IMPALA-4792: Fix number of distinct values for a CASE with constant outputs
Date Thu, 02 Feb 2017 01:42:42 GMT
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 <joemcdonnell@cloudera.com>
Gerrit-Reviewer: Alex Behm <alex.behm@cloudera.com>
Gerrit-Reviewer: Joe McDonnell <joemcdonnell@cloudera.com>
Gerrit-Reviewer: Marcel Kornacker <marcel@cloudera.com>
Gerrit-HasComments: Yes

Mime
View raw message