You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
when I execute sql: select * from user_0003 limit 2,2
Actually the sql statement executed is select * from user_0003 limit 0,4
Which version of ShardingSphere did you use?
5.1.1
Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
ShardingSphere-JDBC
Expected behavior
execute sql: select * from user_0003 limit 2,2
Actual behavior
execute select * from user_0003 limit 0,4
Reason analyze (If you can)
I use database spliting and table spliting both. But the sql only use one table and one dataSource which is default-data-source-name.
I debug the source code and find the reason. When sharding check if the routeContext is single routing, sharding checks the metaData not the sql using. So sharding find 5 dataSources, then the routeContext is not single routing.
Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.
use database spliting and table spliting both. But the sql only use one table and one dataSource which is default-data-source-name.
Example codes for reproduce this issue (such as a github link).
The text was updated successfully, but these errors were encountered:
To remove 'DefaultDataSource ', I would need to change a lot of code because a lot of tables are using 'DefaultDataSource '. Is there another solution? o(╥﹏╥)o
Bug Report
when I execute sql:
select * from user_0003 limit 2,2
Actually the sql statement executed is
select * from user_0003 limit 0,4
Which version of ShardingSphere did you use?
5.1.1
Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
ShardingSphere-JDBC
Expected behavior
execute sql:
select * from user_0003 limit 2,2
Actual behavior
execute
select * from user_0003 limit 0,4
Reason analyze (If you can)
I use database spliting and table spliting both. But the sql only use one table and one dataSource which is default-data-source-name.
I debug the source code and find the reason. When sharding check if the routeContext is single routing, sharding checks the metaData not the sql using. So sharding find 5 dataSources, then the routeContext is not single routing.
Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.
use database spliting and table spliting both. But the sql only use one table and one dataSource which is default-data-source-name.
Example codes for reproduce this issue (such as a github link).
The text was updated successfully, but these errors were encountered: