phoenix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ankit Singhal (JIRA)" <j...@apache.org>
Subject [jira] [Created] (PHOENIX-4733) NPE while running sql through file using psql
Date Wed, 09 May 2018 17:50:00 GMT
Ankit Singhal created PHOENIX-4733:
--------------------------------------

             Summary: NPE while running sql through file using psql
                 Key: PHOENIX-4733
                 URL: https://issues.apache.org/jira/browse/PHOENIX-4733
             Project: Phoenix
          Issue Type: Bug
    Affects Versions: 4.14.0
            Reporter: Srikanth Janardhan
            Assignee: Ankit Singhal
             Fix For: 4.14.0, 5.0.0


{code:java}
cat /tmp/test.sql
CREATE TABLE IF NOT EXISTS QETEST (ID INTEGER NOT NULL PRIMARY KEY, A VARCHAR, B INTEGER);
upsert into QETEST VALUES(1,'A',10);
upsert into QETEST VALUES(2,'B',1000);
upsert into QETEST VALUES(3,'A',20);
upsert into QETEST VALUES(4,'A',100);
upsert into QETEST VALUES(5,'B',9000);
SELECT A||'_GROUP' AS GRP,SUM(B)||'_RESULT' AS SUM FROM QETEST GROUP BY A;
DROP TABLE QETEST;{code}
bin/psql.py localhost /tmp/test.sql


{code:java}
no rows upserted
Time: 0.858 sec(s)

1 row upserted
Time: 0.04 sec(s)

1 row upserted
Time: 0.004 sec(s)

1 row upserted
Time: 0.006 sec(s)

1 row upserted
Time: 0.004 sec(s)

1 row upserted
Time: 0.004 sec(s)

java.lang.NullPointerException: null value in entry: QUERY_I=null
at com.google.common.base.Preconditions.checkNotNull(Preconditions.java:235)
at com.google.common.collect.ImmutableMap.entryOf(ImmutableMap.java:144)
at com.google.common.collect.ImmutableMap$Builder.put(ImmutableMap.java:182)
at org.apache.phoenix.log.QueryLoggerUtil.getInitialDetails(QueryLoggerUtil.java:50)
at org.apache.phoenix.log.QueryLoggerUtil.logInitialDetails(QueryLoggerUtil.java:36)
at org.apache.phoenix.jdbc.PhoenixStatement.createQueryLogger(PhoenixStatement.java:1783)
at org.apache.phoenix.jdbc.PhoenixPreparedStatement.execute(PhoenixPreparedStatement.java:176)
at org.apache.phoenix.jdbc.PhoenixPreparedStatement.execute(PhoenixPreparedStatement.java:183)
at org.apache.phoenix.jdbc.PhoenixConnection.executeStatements(PhoenixConnection.java:468)
at org.apache.phoenix.util.PhoenixRuntime.executeStatements(PhoenixRuntime.java:348)
at org.apache.phoenix.util.PhoenixRuntime.main(PhoenixRuntime.java:295){code}
FYI [~jamestaylor] , if you see it a blocker for 4.14.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message