You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@phoenix.apache.org by "Nick Dimiduk (JIRA)" <ji...@apache.org> on 2015/11/17 01:30:11 UTC

[jira] [Created] (PHOENIX-2425) Invalid sql syntax produces NPE instead of meaningful error message

Nick Dimiduk created PHOENIX-2425:
-------------------------------------

             Summary: Invalid sql syntax produces NPE instead of meaningful error message
                 Key: PHOENIX-2425
                 URL: https://issues.apache.org/jira/browse/PHOENIX-2425
             Project: Phoenix
          Issue Type: Bug
    Affects Versions: 4.6.0
            Reporter: Nick Dimiduk
            Priority: Minor


I would expect a better error message here:

{noformat}
0: jdbc:phoenix:localhost> select * limit 10;
java.lang.NullPointerException
        at org.apache.phoenix.compile.ProjectionCompiler.projectAllTableColumns(ProjectionCompiler.java:140)
        at org.apache.phoenix.compile.ProjectionCompiler.compile(ProjectionCompiler.java:371)
        at org.apache.phoenix.compile.QueryCompiler.compileSingleFlatQuery(QueryCompiler.java:539)
        at org.apache.phoenix.compile.QueryCompiler.compileSingleQuery(QueryCompiler.java:490)
        at org.apache.phoenix.compile.QueryCompiler.compileSelect(QueryCompiler.java:201)
        at org.apache.phoenix.compile.QueryCompiler.compile(QueryCompiler.java:158)
        at org.apache.phoenix.jdbc.PhoenixStatement$ExecutableSelectStatement.compilePlan(PhoenixStatement.java:383)
        at org.apache.phoenix.jdbc.PhoenixStatement$ExecutableSelectStatement.compilePlan(PhoenixStatement.java:357)
        at org.apache.phoenix.jdbc.PhoenixStatement$1.call(PhoenixStatement.java:263)
        at org.apache.phoenix.jdbc.PhoenixStatement$1.call(PhoenixStatement.java:258)
        at org.apache.phoenix.call.CallRunner.run(CallRunner.java:53)
        at org.apache.phoenix.jdbc.PhoenixStatement.executeQuery(PhoenixStatement.java:257)
        at org.apache.phoenix.jdbc.PhoenixStatement.execute(PhoenixStatement.java:1438)
        at sqlline.Commands.execute(Commands.java:822)
        at sqlline.Commands.sql(Commands.java:732)
        at sqlline.SqlLine.dispatch(SqlLine.java:808)
        at sqlline.SqlLine.begin(SqlLine.java:681)
        at sqlline.SqlLine.start(SqlLine.java:398)
        at sqlline.SqlLine.main(SqlLine.java:292)
{noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)