mariadb/mysql-test/suite/galera/t/MDEV-37935.test
Jan Lindström 66aa2501b1 MDEV-37935 : Assertion `0' failed in int wsrep::transaction::before_rollback()
Problem was executable comment in REPLACE that caused
consistency check that is not supported for RSU and
!InnoDB tables.

Fix is to check is Online Schema Upgrade (OSU) method
something else than TOI and if it is then table storage
engine must be InnoDB or error is produced and execution
returns and no consistency check is done.
2025-10-30 17:21:09 +02:00

30 lines
839 B
Text

--source include/galera_cluster.inc
--source include/have_aria.inc
SET sql_mode='';
SET SESSION autocommit=0;
SET SESSION enforce_storage_engine=Aria;
SET WSREP_OSU_METHOD = RSU;
CREATE TABLE t1 (a TEXT) ;
CREATE TABLE t2 (a TEXT) ;
SET SESSION autocommit=1;
--error ER_NOT_SUPPORTED_YET
REPLACE INTO t2 (a) SELECT a from t1;
--error ER_NOT_SUPPORTED_YET
REPLACE INTO t2 (a) SELECT /*!99997 */ a from t1;
SET WSREP_OSU_METHOD = TOI;
DROP TABLE t1,t2;
SET sql_mode='';
SET SESSION autocommit=0;
SET SESSION enforce_storage_engine=MyISAM;
SET WSREP_OSU_METHOD = RSU;
CREATE TABLE t1 (a TEXT) ;
CREATE TABLE t2 (a TEXT) ;
SET SESSION autocommit=1;
--error ER_NOT_SUPPORTED_YET
REPLACE INTO t2 (a) SELECT a from t1;
--error ER_NOT_SUPPORTED_YET
REPLACE INTO t2 (a) SELECT /*!99997 */ a from t1;
SET WSREP_OSU_METHOD = TOI;
DROP TABLE t1,t2;