GitHub user 249550148 opened a pull request:

    https://github.com/apache/phoenix/pull/166

    IndexFailed when data table name contains  ":"

    bin/hbase org.apache.phoenix.mapreduce.index.IndexTool  --data-table 
raw:cell_call --index-table INDEX --output-path hdfs://ip:port/folder
    
    failed when active index table
    
    
    2016-04-23 00:13:06,262 ERROR [main] index.IndexTool:  An exception occured 
while performing the indexing job : 
org.apache.phoenix.exception.PhoenixParserException: ERROR 601 (42P00): Syntax 
error. Encountered ":" at line 1, column 44.
            at 
org.apache.phoenix.exception.PhoenixParserException.newException(PhoenixParserException.java:33)
            at 
org.apache.phoenix.parse.SQLParser.parseStatement(SQLParser.java:111)
            at 
org.apache.phoenix.jdbc.PhoenixStatement$PhoenixStatementParser.parseStatement(PhoenixStatement.java:1185)
            at 
org.apache.phoenix.jdbc.PhoenixStatement.parseStatement(PhoenixStatement.java:1268)
            at 
org.apache.phoenix.jdbc.PhoenixStatement.execute(PhoenixStatement.java:1339)
            at 
org.apache.phoenix.mapreduce.index.IndexToolUtil.updateIndexState(IndexToolUtil.java:72)
            at 
org.apache.phoenix.mapreduce.index.IndexTool.run(IndexTool.java:252)
            at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70)
            at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:84)
            at 
org.apache.phoenix.mapreduce.index.IndexTool.main(IndexTool.java:378)
    Caused by: NoViableAltException(25@[])
            at 
org.apache.phoenix.parse.PhoenixSQLParser.from_table_name(PhoenixSQLParser.java:9170)
            at 
org.apache.phoenix.parse.PhoenixSQLParser.alter_index_node(PhoenixSQLParser.java:2762)
            at 
org.apache.phoenix.parse.PhoenixSQLParser.oneStatement(PhoenixSQLParser.java:838)
            at 
org.apache.phoenix.parse.PhoenixSQLParser.statement(PhoenixSQLParser.java:500)
            at 
org.apache.phoenix.parse.SQLParser.parseStatement(SQLParser.java:108)
            ... 8 more

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/249550148/phoenix master

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/phoenix/pull/166.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #166
    
----
commit 7cebc2cd07dfb4359e3badf95738718a73c0d448
Author: 249550148 <[email protected]>
Date:   2016-04-25T03:06:02Z

    IndexFailed when data table name contains  ":"
    
    bin/hbase org.apache.phoenix.mapreduce.index.IndexTool  --data-table 
raw:cell_call --index-table INDEX --output-path hdfs://ip:port/folder
    
    failed when active index table
    
    
    2016-04-23 00:13:06,262 ERROR [main] index.IndexTool:  An exception occured 
while performing the indexing job : 
org.apache.phoenix.exception.PhoenixParserException: ERROR 601 (42P00): Syntax 
error. Encountered ":" at line 1, column 44.
            at 
org.apache.phoenix.exception.PhoenixParserException.newException(PhoenixParserException.java:33)
            at 
org.apache.phoenix.parse.SQLParser.parseStatement(SQLParser.java:111)
            at 
org.apache.phoenix.jdbc.PhoenixStatement$PhoenixStatementParser.parseStatement(PhoenixStatement.java:1185)
            at 
org.apache.phoenix.jdbc.PhoenixStatement.parseStatement(PhoenixStatement.java:1268)
            at 
org.apache.phoenix.jdbc.PhoenixStatement.execute(PhoenixStatement.java:1339)
            at 
org.apache.phoenix.mapreduce.index.IndexToolUtil.updateIndexState(IndexToolUtil.java:72)
            at 
org.apache.phoenix.mapreduce.index.IndexTool.run(IndexTool.java:252)
            at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70)
            at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:84)
            at 
org.apache.phoenix.mapreduce.index.IndexTool.main(IndexTool.java:378)
    Caused by: NoViableAltException(25@[])
            at 
org.apache.phoenix.parse.PhoenixSQLParser.from_table_name(PhoenixSQLParser.java:9170)
            at 
org.apache.phoenix.parse.PhoenixSQLParser.alter_index_node(PhoenixSQLParser.java:2762)
            at 
org.apache.phoenix.parse.PhoenixSQLParser.oneStatement(PhoenixSQLParser.java:838)
            at 
org.apache.phoenix.parse.PhoenixSQLParser.statement(PhoenixSQLParser.java:500)
            at 
org.apache.phoenix.parse.SQLParser.parseStatement(SQLParser.java:108)
            ... 8 more

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to