Return-Path: X-Original-To: apmail-hive-dev-archive@www.apache.org Delivered-To: apmail-hive-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 57AEB7E7D for ; Thu, 8 Sep 2011 17:51:03 +0000 (UTC) Received: (qmail 31736 invoked by uid 500); 8 Sep 2011 17:51:03 -0000 Delivered-To: apmail-hive-dev-archive@hive.apache.org Received: (qmail 31681 invoked by uid 500); 8 Sep 2011 17:51:02 -0000 Mailing-List: contact dev-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hive.apache.org Delivered-To: mailing list dev@hive.apache.org Received: (qmail 31664 invoked by uid 99); 8 Sep 2011 17:51:02 -0000 Received: from reviews.apache.org (HELO reviews.apache.org) (140.211.11.40) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 08 Sep 2011 17:51:02 +0000 Received: from reviews.apache.org (localhost [127.0.0.1]) by reviews.apache.org (Postfix) with ESMTP id 4B46B1C061C; Thu, 8 Sep 2011 17:51:08 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============6132138005131878886==" MIME-Version: 1.0 Subject: Review Request: Function like with empty string is throwing null pointer exception From: chinnarao@huawei.com To: "John Sichi" Date: Thu, 08 Sep 2011 17:51:08 -0000 Message-ID: <20110908175108.2095.38250@reviews.apache.org> X-ReviewBoard-URL: https://reviews.apache.org X-ReviewRequest-URL: https://reviews.apache.org/r/1757/ Cc: chinnarao@huawei.com,"hive" --===============6132138005131878886== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/1757/ ----------------------------------------------------------- Review request for hive and John Sichi. Summary ------- By default patterntype is complex so it is expecting Pattern object but in = this scenario pattern object is null so it is throwing nullpointer exceptio= n. Default patterntype can be NONE and in parseSimplePattern() it will be a= ssigned with right type. This addresses bug HIVE-2402. https://issues.apache.org/jira/browse/HIVE-2402 Diffs ----- trunk/ql/src/java/org/apache/hadoop/hive/ql/udf/UDFLike.java 1165244 = trunk/ql/src/test/queries/clientpositive/udf_like.q 1165244 = trunk/ql/src/test/results/clientpositive/udf_like.q.out 1165244 = Diff: https://reviews.apache.org/r/1757/diff Testing ------- Added unit testcase. Thanks, chinna --===============6132138005131878886==--