shardingsphere
shardingsphere copied to clipboard
sharding table uses a large number of union all, Actual SQL table name problem
version
shardingsphere-jdbc-core-spring-boot-starter 5.2.1
config
Logic SQL
select count(0) from ( select * from device_alarm where alarm_time <= ? AND mac_sn = 001 union all select * from device_alarm where alarm_time >= ? AND alarm_time <= ? AND mac_sn = 002 union all select * from device_alarm where alarm_time >= ? AND alarm_time <= ? AND mac_sn = 003 union all select * from device_alarm where alarm_time >= ? AND alarm_time <= ? AND mac_sn = 004 union all select * from device_alarm where alarm_time >= ? AND alarm_time <= ? AND mac_sn = 005 union all select * from device_alarm where alarm_time >= ? AND mac_sn = 006 ) table_count
Actual SQL
Hi @wting1123 Thanks for your feedback, can you try the latest version 5.4.1?
There hasn't been any activity on this issue recently, and in order to prioritize active issues, it will be marked as stale.
Closed due to no response. If this problem persists, please reopen it or submit a new one.