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 2020/07/16 02:41:48 UTC

[GitHub] [shardingsphere] slowquery opened a new issue #6363: I think SQLParser is an error

slowquery opened a new issue #6363:
URL: https://github.com/apache/shardingsphere/issues/6363


   ## Bug Report
   
   i try sharding on Amaon RDS with mysql, but isn't not supported error
   also example code is mysql, what is a problem?
   
   ```
   java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'
   	at org.apache.shardingsphere.sql.parser.core.parser.SQLParserFactory.newInstance(SQLParserFactory.java:55)
   	at org.apache.shardingsphere.sql.parser.core.parser.SQLParserExecutor.towPhaseParse(SQLParserExecutor.java:55)
   	at org.apache.shardingsphere.sql.parser.core.parser.SQLParserExecutor.execute(SQLParserExecutor.java:47)
   	at org.apache.shardingsphere.sql.parser.SQLParserEngine.parse0(SQLParserEngine.java:79)
   	at org.apache.shardingsphere.sql.parser.SQLParserEngine.parse(SQLParserEngine.java:61)
   	at org.apache.shardingsphere.underlying.route.DataNodeRouter.createRouteContext(DataNodeRouter.java:97)
   	at org.apache.shardingsphere.underlying.route.DataNodeRouter.executeRoute(DataNodeRouter.java:89)
   	at org.apache.shardingsphere.underlying.route.DataNodeRouter.route(DataNodeRouter.java:76)
   	at org.apache.shardingsphere.underlying.pluggble.prepare.PreparedQueryPrepareEngine.route(PreparedQueryPrepareEngine.java:54)
   	at org.apache.shardingsphere.underlying.pluggble.prepare.BasePrepareEngine.executeRoute(BasePrepareEngine.java:96)
   	at org.apache.shardingsphere.underlying.pluggble.prepare.BasePrepareEngine.prepare(BasePrepareEngine.java:83)
   	at org.apache.shardingsphere.shardingjdbc.jdbc.core.statement.ShardingPreparedStatement.prepare(ShardingPreparedStatement.java:183)
   	at org.apache.shardingsphere.shardingjdbc.jdbc.core.statement.ShardingPreparedStatement.executeUpdate(ShardingPreparedStatement.java:131)
   ```
   


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



[GitHub] [shardingsphere] kimmking commented on issue #6363: I think SQLParser is an error

Posted by GitBox <gi...@apache.org>.
kimmking commented on issue #6363:
URL: https://github.com/apache/shardingsphere/issues/6363#issuecomment-659378995


   you can try:
   >  String createBlockSQL = "INSERT INTO Block (DomainId, BlockName, BlockTimestamp)" +
         " VALUES (?, ?, ?)";


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



[GitHub] [shardingsphere] slowquery commented on issue #6363: I think SQLParser is an error

Posted by GitBox <gi...@apache.org>.
slowquery commented on issue #6363:
URL: https://github.com/apache/shardingsphere/issues/6363#issuecomment-659397347


   it is same problem
   can you check 'Cannot support database type' Exception throw logic check?


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



[GitHub] [shardingsphere] slowquery commented on issue #6363: I think SQLParser is an error

Posted by GitBox <gi...@apache.org>.
slowquery commented on issue #6363:
URL: https://github.com/apache/shardingsphere/issues/6363#issuecomment-659248697


   yaml & java same this.
   mysql connect is successfully, but SQL execute error


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



[GitHub] [shardingsphere] slowquery commented on issue #6363: I think SQLParser is an error

Posted by GitBox <gi...@apache.org>.
slowquery commented on issue #6363:
URL: https://github.com/apache/shardingsphere/issues/6363#issuecomment-659321147


   ```
    String createBlockSQL = "INSERT INTO Block (DomainId, BlockName, BlockTimestamp)" +
         "VALUES (?, ?, ?, ?)";
         PreparedStatement createBlockQuery = conn.prepareStatement(createBlockSQL, Statement.RETURN_GENERATED_KEYS);
   
         Timestamp ts = new Timestamp(this.BlockTimestamp);
   
         createBlockQuery.setInt(1, this.DomainId);
         createBlockQuery.setInt(2, this.BlockName);
         createBlockQuery.setTimestamp(3, ts);
   
         int createBlockResult = createBlockQuery.executeUpdate();
   ```
   
   createBlockQuery.executeUpdate(); this function execute, an error occurred


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



[GitHub] [shardingsphere] slowquery commented on issue #6363: I think SQLParser is an error

Posted by GitBox <gi...@apache.org>.
slowquery commented on issue #6363:
URL: https://github.com/apache/shardingsphere/issues/6363#issuecomment-659809941


   Sorry, i mistake.
   
   i'm not added build.gradle
   ```
   implementation 'org.apache.shardingsphere:shardingsphere-sql-parser-mysql:4.1.1'
   ```
   
   close 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



[GitHub] [shardingsphere] slowquery closed issue #6363: I think SQLParser is an error

Posted by GitBox <gi...@apache.org>.
slowquery closed issue #6363:
URL: https://github.com/apache/shardingsphere/issues/6363


   


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



[GitHub] [shardingsphere] slowquery edited a comment on issue #6363: I think SQLParser is an error

Posted by GitBox <gi...@apache.org>.
slowquery edited a comment on issue #6363:
URL: https://github.com/apache/shardingsphere/issues/6363#issuecomment-659397347


   it is same problem
   can you check 'Cannot support database type' for Exception throw logic?


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



[GitHub] [shardingsphere] tristaZero commented on issue #6363: I think SQLParser is an error

Posted by GitBox <gi...@apache.org>.
tristaZero commented on issue #6363:
URL: https://github.com/apache/shardingsphere/issues/6363#issuecomment-659294830


   @slowquery Hi
   What is your SQL inputted?


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