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
step 1: set mysql to read only
$ mysql -uroot -p
mysql> set global read_only=ON;
mysql> flush tables with read lock;
step 2: write a test application which inserts a record into the test table.
SQLErrorCodeSQLExceptionTranslator object will be built with datasource input parameter, MetaDataAccessException will be triggered at JdbcUtils.extractDatabaseMetaData call, and a new SQLErrorCodes() will be built as the sqlErrorCodes of the SQLErrorCodeSQLExceptionTranslator object.
step 3: set mysql to read/write
$ mysql -uroot -p
mysql> set global read_only=OFF;
mysql> unlock tables;
step4: continue the test application to insert two same records into the test table which has unique key.
the SQLErrorCodeSQLExceptionTranslator object could not do anything but return null because it;s sqlErrorCodes has empty duplicateKeyCodes.
The text was updated successfully, but these errors were encountered:
Affects: \5.2.5.RELEASE(spring-jdbc)
mysql-connector-java: 8.0.19
mybatis-spring-boot-starter: 2.1.2
spring-boot-starter-jdbc: 2.2.6.RELEASE
step 1: set mysql to read only
$ mysql -uroot -p
mysql> set global read_only=ON;
mysql> flush tables with read lock;
step 2: write a test application which inserts a record into the test table.
SQLErrorCodeSQLExceptionTranslator object will be built with datasource input parameter, MetaDataAccessException will be triggered at JdbcUtils.extractDatabaseMetaData call, and a new SQLErrorCodes() will be built as the sqlErrorCodes of the SQLErrorCodeSQLExceptionTranslator object.
step 3: set mysql to read/write
$ mysql -uroot -p
mysql> set global read_only=OFF;
mysql> unlock tables;
step4: continue the test application to insert two same records into the test table which has unique key.
the SQLErrorCodeSQLExceptionTranslator object could not do anything but return null because it;s sqlErrorCodes has empty duplicateKeyCodes.
The text was updated successfully, but these errors were encountered: