Zach Amsden has posted comments on this change. ( http://gerrit.cloudera.org:8080/9339 )
Change subject: IMPALA-6405: Error when string to decimal cast overflows ...................................................................... Patch Set 1: (2 comments) http://gerrit.cloudera.org:8080/#/c/9339/1//COMMIT_MSG Commit Message: http://gerrit.cloudera.org:8080/#/c/9339/1//COMMIT_MSG@10 PS1, Line 10: a decimal, a MULL was returned. In this patch, we change this behavior NULL http://gerrit.cloudera.org:8080/#/c/9339/1/fe/src/main/java/org/apache/impala/rewrite/RemoveRedundantStringCast.java File fe/src/main/java/org/apache/impala/rewrite/RemoveRedundantStringCast.java: http://gerrit.cloudera.org:8080/#/c/9339/1/fe/src/main/java/org/apache/impala/rewrite/RemoveRedundantStringCast.java@85 PS1, Line 85: if (resultOfReverseCast != null && It seems weird (at least to me) that LiteralExpr.create would return null instead of NullLiteral, and probably simpler to just make this the case even if errors are raised during the cast. It also seems strange that we would only hit this with decimal. Don't other casts also raise errors? -- To view, visit http://gerrit.cloudera.org:8080/9339 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Icffccac1c1c2361447ae4b0de9b6c2ec7de071db Gerrit-Change-Number: 9339 Gerrit-PatchSet: 1 Gerrit-Owner: Taras Bobrovytsky <[email protected]> Gerrit-Reviewer: Alex Behm <[email protected]> Gerrit-Reviewer: Zach Amsden <[email protected]> Gerrit-Comment-Date: Thu, 15 Feb 2018 23:19:06 +0000 Gerrit-HasComments: Yes
