You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2019/06/05 18:43:36 UTC

[GitHub] [spark] dongjoon-hyun commented on issue #24749: [SPARK-27890][SQL] Improve SQL parser error message for identifier with hyphens except those in expressions

dongjoon-hyun commented on issue #24749: [SPARK-27890][SQL] Improve SQL parser error message for identifier with hyphens except those in expressions
URL: https://github.com/apache/spark/pull/24749#issuecomment-499206853
 
 
   Not only for the expressions, we cannot handle `a1-1` inside `FROM`. We only handle `a1-b1` and `a1-1b`. Not `a1-1`. Could you describe that, too?
   ```
   spark-sql> select * from a1-b1;
   Error in query:
   Possibly unquoted identifier a1-b1 detected. Please consider quoting it with back-quotes as `a1-b1`(line 1, pos 16)
   
   == SQL ==
   select * from a1-b1
   ----------------^^^
   
   spark-sql> select * from a1-1b;
   Error in query:
   Possibly unquoted identifier a1-1b detected. Please consider quoting it with back-quotes as `a1-1b`(line 1, pos 16)
   
   == SQL ==
   select * from a1-1b
   ----------------^^^
   
   spark-sql> select * from a1-1;
   Error in query:
   mismatched input 'from' expecting {<EOF>, 'CLUSTER', 'DISTRIBUTE', 'EXCEPT', 'GROUP', 'HAVING', 'INTERSECT', 'LATERAL', 'LIMIT', 'ORDER', 'MINUS', 'SORT', 'UNION', 'WHERE', 'WINDOW'}(line 1, pos 9)
   
   == SQL ==
   select * from a1-1
   ---------^^^
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org