shijie-328931589 opened a new issue, #30939:
URL: https://github.com/apache/shardingsphere/issues/30939

   ## Bug Report
   
   ### Which version of ShardingSphere did you use?
   5.4.1
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   ShardingSphere-JDBC
   ### Expected behavior
   the simple table should not appear InconsistentShardingTableMetaDataException
   ### Actual behavior
   Caused by: 
org.apache.shardingsphere.sharding.exception.metadata.InconsistentShardingTableMetaDataException:
 Can not get uniformed table structure for logic table `normal_record`, it has 
different meta data of actual tables are as follows: 
   actual table: normal_record, meta data: TableMetaData(name=normal_record, 
columns=[ColumnMetaData(name=id, dataType=-5, primaryKey=true, generated=true, 
caseSensitive=true, visible=true, unsigned=false, nullable=false), 
ColumnMetaData(name=description, dataType=12, primaryKey=false, 
generated=false, caseSensitive=true, visible=true, unsigned=false, 
nullable=true)], indexes=[IndexMetaData(name=normal_record_pkey, columns=[id], 
unique=true)], constraints=[])
   actual table: normal_record, meta data: TableMetaData(name=normal_record, 
columns=[ColumnMetaData(name=id, dataType=-5, primaryKey=true, generated=true, 
caseSensitive=true, visible=true, unsigned=false, nullable=false), 
ColumnMetaData(name=description, dataType=12, primaryKey=false, 
generated=false, caseSensitive=true, visible=true, unsigned=false, 
nullable=true)], indexes=[IndexMetaData(name=normal_record_pkey, columns=[id], 
unique=true)], constraints=[])
   
   
![error10](https://github.com/apache/shardingsphere/assets/15098935/a0d27c5c-4b8c-4058-a5d2-78d34a2485d8)
   
   ### Reason analyze (If you can)
   In TableMetaData definition,the field ’indexes‘ is Collection; In the 
running, the collection type is AbstractMapBasedMultimap.WrappedSet for the 
field 'indexes' and 'constraints' , In WrappedSet , equal and hashset is not 
suitable for this scene.
   
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule 
configuration, when exception occur etc.
   in sharding database,use the same datasource to config,and set 
CHECK_TABLE_METADATA_ENABLED true
   
   ### Example codes for reproduce this issue (such as a github link).
   


-- 
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: 
[email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to