Return-Path: X-Original-To: apmail-phoenix-commits-archive@minotaur.apache.org Delivered-To: apmail-phoenix-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id C63271722C for ; Wed, 29 Oct 2014 00:01:57 +0000 (UTC) Received: (qmail 81795 invoked by uid 500); 29 Oct 2014 00:01:57 -0000 Delivered-To: apmail-phoenix-commits-archive@phoenix.apache.org Received: (qmail 81708 invoked by uid 500); 29 Oct 2014 00:01:57 -0000 Mailing-List: contact commits-help@phoenix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@phoenix.apache.org Delivered-To: mailing list commits@phoenix.apache.org Received: (qmail 81450 invoked by uid 99); 29 Oct 2014 00:01:57 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 29 Oct 2014 00:01:57 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 356AB998FEC; Wed, 29 Oct 2014 00:01:57 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: jamestaylor@apache.org To: commits@phoenix.apache.org Date: Wed, 29 Oct 2014 00:02:06 -0000 Message-Id: <40dd4c9b880440278320f91fee7f9ee2@git.apache.org> In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [11/15] git commit: PHOENIX-1376 java.lang.NullPointerException occurs in JDBC driver PHOENIX-1376 java.lang.NullPointerException occurs in JDBC driver Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/72144f17 Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/72144f17 Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/72144f17 Branch: refs/heads/3.2 Commit: 72144f17884518b1152b83d294b77f10c2a743a5 Parents: 2681601 Author: James Taylor Authored: Mon Oct 27 13:40:47 2014 -0700 Committer: James Taylor Committed: Mon Oct 27 13:45:38 2014 -0700 ---------------------------------------------------------------------- .../src/main/java/org/apache/phoenix/jdbc/PhoenixResultSet.java | 5 ----- .../main/java/org/apache/phoenix/schema/tuple/ResultTuple.java | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/phoenix/blob/72144f17/phoenix-core/src/main/java/org/apache/phoenix/jdbc/PhoenixResultSet.java ---------------------------------------------------------------------- diff --git a/phoenix-core/src/main/java/org/apache/phoenix/jdbc/PhoenixResultSet.java b/phoenix-core/src/main/java/org/apache/phoenix/jdbc/PhoenixResultSet.java index e662a3f..8a6cf64 100644 --- a/phoenix-core/src/main/java/org/apache/phoenix/jdbc/PhoenixResultSet.java +++ b/phoenix-core/src/main/java/org/apache/phoenix/jdbc/PhoenixResultSet.java @@ -1232,9 +1232,4 @@ public class PhoenixResultSet implements ResultSet, SQLCloseable, org.apache.pho public T getObject(String columnLabel, Class type) throws SQLException { return (T) getObject(columnLabel); // Just ignore type since we only support built-in types } - - @Override - public String toString(){ - return "ResultSet:\n"+ "\tclosed: "+this.isClosed+"\n\tcurrent row: "+currentRow; - } } \ No newline at end of file http://git-wip-us.apache.org/repos/asf/phoenix/blob/72144f17/phoenix-core/src/main/java/org/apache/phoenix/schema/tuple/ResultTuple.java ---------------------------------------------------------------------- diff --git a/phoenix-core/src/main/java/org/apache/phoenix/schema/tuple/ResultTuple.java b/phoenix-core/src/main/java/org/apache/phoenix/schema/tuple/ResultTuple.java index 02aebf7..f0dbd9e 100644 --- a/phoenix-core/src/main/java/org/apache/phoenix/schema/tuple/ResultTuple.java +++ b/phoenix-core/src/main/java/org/apache/phoenix/schema/tuple/ResultTuple.java @@ -62,7 +62,7 @@ public class ResultTuple extends BaseTuple { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("keyvalues="); - if(this.result.isEmpty()) { + if(this.result == null || this.result.isEmpty()) { sb.append("NONE"); return sb.toString(); }