You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2021/03/15 09:09:07 UTC

[GitHub] [shardingsphere] Liangda-w commented on issue #9668: ORACLE SQL 'IDENTIFIER_' rule is not correct in Literals.g4

Liangda-w commented on issue #9668:
URL: https://github.com/apache/shardingsphere/issues/9668#issuecomment-799249003


   Hi @wgy8283335, 
   Your suggestion won't work properly, because if you put `PASSWORD_` before `IDENTIFIER_`, many words like for example `abc123` will be assigned `PASSWORD_` first instead of `IDENTIFIER_`, which breaks the rule for other SQL 🤔 
   
   An example with `PASSWORD_`:
   ![parseTree](https://user-images.githubusercontent.com/66914151/111127913-9eb08080-8574-11eb-8bc5-f45d284942a8.png)
   
   Why do you think `[A-Za-z_$0-9]*?[A-Za-z_$]+?[A-Za-z_$0-9]` is necessary? According to the [Oracle Database Object Naming Rules](https://docs.oracle.com/en/database/oracle/oracle-database/19/sqlrf/Database-Object-Names-and-Qualifiers.html#GUID-75337742-67FD-4EC0-985F-741C93D918DA), I think the current `IDENTIFIER_` rule is more accurate.
   
   > Nonquoted identifiers must begin with an alphabetic character from your database character set. Quoted identifiers can begin with any character.
   
   Please correct me if I'm thinking wrong:) Maybe we could also use the previous `IDENTIFIER_` for `password` to solve this issue.


----------------------------------------------------------------
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