You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by "bigno-feng (via GitHub)" <gi...@apache.org> on 2023/05/15 11:39:33 UTC

[GitHub] [shardingsphere] bigno-feng opened a new issue, #25679: select last_insert_in() is not work

bigno-feng opened a new issue, #25679:
URL: https://github.com/apache/shardingsphere/issues/25679

   version: 5.3.2
   
   ![image](https://github.com/apache/shardingsphere/assets/37724987/cb74c127-f04d-48b8-825c-e7210f3e9950)
   ![image](https://github.com/apache/shardingsphere/assets/37724987/fb4f5e04-c388-41a1-b3e7-6741d3bc0f9e)
   


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

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


[GitHub] [shardingsphere] FlyingZC commented on issue #25679: SELECT LAST_INSERT_ID() is not working

Posted by "FlyingZC (via GitHub)" <gi...@apache.org>.
FlyingZC commented on issue #25679:
URL: https://github.com/apache/shardingsphere/issues/25679#issuecomment-1548884336

   @bigno-feng Hi, please check your configuration.I tested that the following configuration can be executed normally in version 5.3.2.
   You can debug the method of `org.apache.shardingsphere.readwritesplitting.route.impl.ReadwriteSplittingDataSourceRouter#route`.
   ```yaml
   databaseName: readwrite_splitting_db
     
   dataSources:
     write_ds:
       dataSourceClassName: com.zaxxer.hikari.HikariDataSource
       driverClassName: com.mysql.jdbc.Driver
       jdbcUrl: jdbc:mysql://localhost:3306/demo_write_ds?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
       username: root
       password: root
       autoCommit: true
     read_ds_0:
       dataSourceClassName: com.zaxxer.hikari.HikariDataSource
       driverClassName: com.mysql.jdbc.Driver
       jdbcUrl: jdbc:mysql://localhost:3306/demo_read_ds_0?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
       username: root
       password: root
       autoCommit: true
     read_ds_1:
       dataSourceClassName: com.zaxxer.hikari.HikariDataSource
       driverClassName: com.mysql.jdbc.Driver
       jdbcUrl: jdbc:mysql://localhost:3306/demo_read_ds_1?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
       username: root
       password: root
       autoCommit: true
   
   rules:
     - !READWRITE_SPLITTING
       dataSources:
         readwrite_ds:
           staticStrategy:
             writeDataSourceName: write_ds
             readDataSourceNames:
               - read_ds_0
               - read_ds_1
           loadBalancerName: random
       loadBalancers:
         random:
           type: RANDOM
           props:
             transaction-read-query-strategy: FIXED_PRIMARY
         weight_lb:
           type: WEIGHT
           props:
             read_ds_0: 1
             read_ds_1: 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.

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

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