1--source include/have_innodb.inc 2# 3# Bug #24200: Provide backwards compatibility mode for 4.x "rollback on 4# transaction timeout" 5# 6--disable_warnings 7drop table if exists t1; 8--enable_warnings 9 10show variables like 'innodb_rollback_on_timeout'; 11create table t1 (a int unsigned not null primary key) engine = innodb; 12insert into t1 values (1); 13commit; 14connect (con1,localhost,root,,); 15connect (con2,localhost,root,,); 16 17connection con2; 18begin work; 19insert into t1 values (2); 20select * from t1; 21 22connection con1; 23begin work; 24insert into t1 values (5); 25select * from t1; 26# Lock wait timeout set to 2 seconds in <THIS TEST>-master.opt; this 27# statement will time out; in 5.0.13+, it will not roll back transaction. 28--error ER_LOCK_WAIT_TIMEOUT 29insert into t1 values (2); 30# On 5.0.13+, this should give ==> 1, 5 31select * from t1; 32commit; 33 34connection con2; 35select * from t1; 36commit; 37 38connection default; 39select * from t1; 40drop table t1; 41disconnect con1; 42disconnect con2; 43