[
https://issues.apache.org/jira/browse/IMPALA-941?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16439418#comment-16439418
]
abipc edited comment on IMPALA-941 at 5/25/18 8:13 AM:
-------------------------------------------------------
# Able to add test case to ParserTest and reproduce the issue
# Tried to move parse rule for IdentifierOrKw above parse rule for
Integers/Decimal Literal in flex file, but it did not work.
# According to my analysis, issue with #2 was because of DOT - neither
Character.isJavaIdentifierStart nor Character.isJavaIdentifierPart
# So made IdentifierOrKw parse rule as -{color:#f79232}
[.]*{color}[:digit:]*[:jletter:][:jletterdigit:]* | "&&" | "||"
# Now the test case in the ticket *PASSES* but obviously other tests fail
[~jbapple] Need some direction here. (Just FYI, table names starting with
numbers are not allowed in Spark SQL etc unless quoted which Impala also
supports.)
was (Author: abipc):
# Able to add test case to ParserTest and reproduce the issue
# Tried to move parse rule for IdentifierOrKw above parse rule for
Integers/Decimal Literal in flex file, but it did not work.
# According to my analysis, issue with #2 was because of DOT - neither
Character.isJavaIdentifierStart nor Character.isJavaIdentifierPart
# So made IdentifierOrKw parse rule as -{color:#f79232}
[.]*{color}[:digit:]*[:jletter:][:jletterdigit:]* | "&&" | "||"
# Now the test case in the ticket *PASSES* but obviously other tests fail
[~jbapple] Need some direction here. (Just FYI, table names starting with
numbers are not allowed for MySQL/PostGreSQL, Spark SQL etc unless quoted
which Impala also supports.)
> 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: abipc
> Priority: Minor
> Labels: customer, newbie
>
> 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: [email protected]
For additional commands, e-mail: [email protected]