You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "ASF subversion and git services (JIRA)" <ji...@apache.org> on 2018/11/14 20:24:00 UTC
[jira] [Commented] (IMPALA-941) Impala Parser issue when using
fully qualified table names that start with a number.
[ https://issues.apache.org/jira/browse/IMPALA-941?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16687075#comment-16687075 ]
ASF subversion and git services commented on IMPALA-941:
--------------------------------------------------------
Commit c4c1eba6b74de1e3902005e56141839833592954 in impala's branch refs/heads/master from [~fredyw]
[ https://git-wip-us.apache.org/repos/asf?p=impala.git;h=c4c1eba ]
IMPALA-941: Fix support for an identifier that starts with a number
Impala has supported an identifier that starts with a number for quite
some time. However, its implementation was broken, especially when it
comes to using it in a fully-qualified name because IDENTIFIER DOT
IDENTIFIER was lexed to DECIMAL_LITERAL. This patch fixes the scanner
to fix support for an idenfifier that starts with a number.
For example:
Before the fix:
> select * from 123_bar; --> this is OK
> select * from foo. 123_bar; --> this is OK
> select * from foo .123_bar; --> this is not OK
> select * from foo.123_bar; --> this is not OK
After the fix:
> select * from 123_bar; --> this is OK
> select * from foo. 123_bar; --> this is OK
> select * from foo .123_bar; --> this is OK
> select * from foo.123_bar; --> this is OK
Testing:
- Added a new parser test
- Ran all FE tests
Change-Id: I8a715be73553247ce80a1ba841712191d64f9730
Reviewed-on: http://gerrit.cloudera.org:8080/11927
Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
> Impala Parser issue when using fully qualified table names that start with a number.
> ------------------------------------------------------------------------------------
>
> Key: IMPALA-941
> URL: https://issues.apache.org/jira/browse/IMPALA-941
> Project: IMPALA
> Issue Type: Bug
> Components: Frontend
> Affects Versions: Impala 1.2.4
> Reporter: Udai Kiran Potluri
> Assignee: Fredy Wijaya
> Priority: Minor
> Labels: customer, newbie
> Fix For: Impala 3.2.0
>
>
> Impala Parser issue when using fully qualified table names that start with a number.
> What is going wrong is that Impala is parsing the table name as a floating point literal since the text starts with a number and contains a period.
> {code}
> INVALIDATE METADATA db.571_market;
> Query: invalidate METADATA db.571_market
> ERROR: AnalysisException: Syntax error in line 1:
> invalidate METADATA db.571_market
> ^
> Encountered: FLOATING POINT LITERAL
> Expected: ADD, AS, CHANGE, COMMENT, CROSS, DROP, FULL, GROUP, HAVING, INNER, JOIN, LEFT, LIKE, LIMIT, LOCATION, ON, ORDER, PARTITION, RENAME, REPLACE, RIGHT, ROW, SELECT, SET, STORED, TBLPROPERTIES, UNION, USING, VALUES, WHERE, WITH, COMMA, IDENTIFIER
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org