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/08/26 06:26:28 UTC

[GitHub] [shardingsphere] lanchengx opened a new pull request #12018: Fixes #12012, Get the exactly value in backquotes

lanchengx opened a new pull request #12018:
URL: https://github.com/apache/shardingsphere/pull/12018


   Fixes #12012.
   
   Changes proposed in this pull request:
   - Get the exactly value in backquotes
   


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] strongduanmu commented on a change in pull request #12018: Fixes #12012, Get the exactly value in backquotes

Posted by GitBox <gi...@apache.org>.
strongduanmu commented on a change in pull request #12018:
URL: https://github.com/apache/shardingsphere/pull/12018#discussion_r696380463



##########
File path: shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/statement/impl/MySQLDDLStatementSQLVisitor.java
##########
@@ -193,7 +194,7 @@ public ASTNode visitDropView(final DropViewContext ctx) {
     @Override
     public ASTNode visitCreateDatabase(final CreateDatabaseContext ctx) {
         MySQLCreateDatabaseStatement result = new MySQLCreateDatabaseStatement();
-        result.setDatabaseName(ctx.schemaName().getText());
+        result.setDatabaseName(SQLUtil.getExactlyValue(ctx.schemaName().getText()));

Review comment:
       @lanchengx Maybe use `StringLiteralValue` to handle backquote is better.




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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] lanchengx commented on pull request #12018: Fixes #12012, Get the exactly value in backquotes

Posted by GitBox <gi...@apache.org>.
lanchengx commented on pull request #12018:
URL: https://github.com/apache/shardingsphere/pull/12018#issuecomment-906232746


   > Can you add some parse test cases?
   
   @strongduanmu  Thanks, this test has been added.


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] strongduanmu merged pull request #12018: Fixes #12012, Get the exactly value in backquotes

Posted by GitBox <gi...@apache.org>.
strongduanmu merged pull request #12018:
URL: https://github.com/apache/shardingsphere/pull/12018


   


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] strongduanmu commented on pull request #12018: Fixes #12012, Get the exactly value in backquotes

Posted by GitBox <gi...@apache.org>.
strongduanmu commented on pull request #12018:
URL: https://github.com/apache/shardingsphere/pull/12018#issuecomment-906177594


   Can you add some parse test cases?


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org