Alex Behm has posted comments on this change. Change subject: IMPALA-5030: Adds support for NVL2() function ......................................................................
Patch Set 3: (1 comment) http://gerrit.cloudera.org:8080/#/c/6962/3/fe/src/main/java/org/apache/impala/analysis/FunctionCallExpr.java File fe/src/main/java/org/apache/impala/analysis/FunctionCallExpr.java: Line 100: plist.add(new IsNullPredicate(params.exprs().get(0), true)); What if NVL2() is called without params? How about doing: List<Expr> plist = Lists.newArrayList(params.exprs()); if (!plist.isEmpty()) { plist.set(0, new IsNullPredicate(plist.get(0), true)); } return new FunctionCallExpr("if", plist); -- To view, visit http://gerrit.cloudera.org:8080/6962 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: I32b03e9864f46c9c5e482280d1aa676ff7f02644 Gerrit-PatchSet: 3 Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-Owner: Vincent Tran <[email protected]> Gerrit-Reviewer: Alex Behm <[email protected]> Gerrit-Reviewer: Michael Ho <[email protected]> Gerrit-Reviewer: Vincent Tran <[email protected]> Gerrit-HasComments: Yes
