# generated by tokudb_update_decr_floor.py source include/have_tokudb.inc; source include/have_innodb.inc; set default_storage_engine='tokudb'; disable_warnings; drop table if exists t; enable_warnings; set tokudb_disable_slow_update=1; create table tt ( id tinyint null primary key, x tinyint null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; replace_regex /MariaDB/XYZ/ /MySQL/XYZ/; error ER_UNSUPPORTED_EXTENSION; update noar tt set x=if(x=0,0,x-1) where id=1; drop table tt, ti; create table tt ( id tinyint not null primary key, x tinyint not null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; replace_regex /MariaDB/XYZ/ /MySQL/XYZ/; error ER_UNSUPPORTED_EXTENSION; update noar tt set x=if(x=0,0,x-1) where id=1; drop table tt, ti; create table tt ( id tinyint unsigned null primary key, x tinyint unsigned null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; # try to decrement when x=0 update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; let $diff_tables = test.tt, test.ti; source include/diff_tables.inc; drop table tt, ti; create table tt ( id tinyint unsigned not null primary key, x tinyint unsigned not null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; # try to decrement when x=0 update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; let $diff_tables = test.tt, test.ti; source include/diff_tables.inc; drop table tt, ti; create table tt ( id smallint null primary key, x smallint null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; replace_regex /MariaDB/XYZ/ /MySQL/XYZ/; error ER_UNSUPPORTED_EXTENSION; update noar tt set x=if(x=0,0,x-1) where id=1; drop table tt, ti; create table tt ( id smallint not null primary key, x smallint not null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; replace_regex /MariaDB/XYZ/ /MySQL/XYZ/; error ER_UNSUPPORTED_EXTENSION; update noar tt set x=if(x=0,0,x-1) where id=1; drop table tt, ti; create table tt ( id smallint unsigned null primary key, x smallint unsigned null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; # try to decrement when x=0 update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; let $diff_tables = test.tt, test.ti; source include/diff_tables.inc; drop table tt, ti; create table tt ( id smallint unsigned not null primary key, x smallint unsigned not null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; # try to decrement when x=0 update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; let $diff_tables = test.tt, test.ti; source include/diff_tables.inc; drop table tt, ti; create table tt ( id mediumint null primary key, x mediumint null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; replace_regex /MariaDB/XYZ/ /MySQL/XYZ/; error ER_UNSUPPORTED_EXTENSION; update noar tt set x=if(x=0,0,x-1) where id=1; drop table tt, ti; create table tt ( id mediumint not null primary key, x mediumint not null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; replace_regex /MariaDB/XYZ/ /MySQL/XYZ/; error ER_UNSUPPORTED_EXTENSION; update noar tt set x=if(x=0,0,x-1) where id=1; drop table tt, ti; create table tt ( id mediumint unsigned null primary key, x mediumint unsigned null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; # try to decrement when x=0 update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; let $diff_tables = test.tt, test.ti; source include/diff_tables.inc; drop table tt, ti; create table tt ( id mediumint unsigned not null primary key, x mediumint unsigned not null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; # try to decrement when x=0 update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; let $diff_tables = test.tt, test.ti; source include/diff_tables.inc; drop table tt, ti; create table tt ( id int null primary key, x int null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; replace_regex /MariaDB/XYZ/ /MySQL/XYZ/; error ER_UNSUPPORTED_EXTENSION; update noar tt set x=if(x=0,0,x-1) where id=1; drop table tt, ti; create table tt ( id int not null primary key, x int not null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; replace_regex /MariaDB/XYZ/ /MySQL/XYZ/; error ER_UNSUPPORTED_EXTENSION; update noar tt set x=if(x=0,0,x-1) where id=1; drop table tt, ti; create table tt ( id int unsigned null primary key, x int unsigned null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; # try to decrement when x=0 update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; let $diff_tables = test.tt, test.ti; source include/diff_tables.inc; drop table tt, ti; create table tt ( id int unsigned not null primary key, x int unsigned not null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; # try to decrement when x=0 update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; let $diff_tables = test.tt, test.ti; source include/diff_tables.inc; drop table tt, ti; create table tt ( id bigint null primary key, x bigint null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; replace_regex /MariaDB/XYZ/ /MySQL/XYZ/; error ER_UNSUPPORTED_EXTENSION; update noar tt set x=if(x=0,0,x-1) where id=1; drop table tt, ti; create table tt ( id bigint not null primary key, x bigint not null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; replace_regex /MariaDB/XYZ/ /MySQL/XYZ/; error ER_UNSUPPORTED_EXTENSION; update noar tt set x=if(x=0,0,x-1) where id=1; drop table tt, ti; create table tt ( id bigint unsigned null primary key, x bigint unsigned null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; # try to decrement when x=0 update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; let $diff_tables = test.tt, test.ti; source include/diff_tables.inc; drop table tt, ti; create table tt ( id bigint unsigned not null primary key, x bigint unsigned not null ); insert into tt values (1,4); create table ti like tt; alter table ti engine=innodb; insert into ti select * from tt; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; # try to decrement when x=0 update noar tt set x=if(x=0,0,x-1) where id=1; update noar ti set x=if(x=0,0,x-1) where id=1; let $diff_tables = test.tt, test.ti; source include/diff_tables.inc; drop table tt, ti;