1set tokudb_enable_fast_update=1;
2set session sql_mode=(select replace(@@sql_mode,'STRICT_TRANS_TABLES',''));
3set session sql_mode=(select replace(@@sql_mode,'STRICT_ALL_TABLES',''));
4create table tt (id int primary key, c char(32), b binary(32)) engine = tokudb;
5create table ti like tt;
6alter table ti engine=innodb;
7insert into tt values (1,null,null);
8insert into ti values (1,null,null);
9update tt set c='hi' where id=1;
10update ti set c='hi' where id=1;
11include/diff_tables.inc [test.tt, test.ti]
12update tt set c='there' where id=1;
13update ti set c='there' where id=1;
14include/diff_tables.inc [test.tt, test.ti]
15drop table tt, ti;
16create table tt (id char(8) primary key,
17c char(32),
18b binary(32)) engine = tokudb;
19create table ti like tt;
20alter table ti engine=innodb;
21insert into tt values ('1',null,null);
22insert into ti values ('1',null,null);
23update tt set c='hi' where id='1';
24update ti set c='hi' where id='1';
25include/diff_tables.inc [test.tt, test.ti]
26update tt set c='there' where id='1';
27update ti set c='there' where id='1';
28include/diff_tables.inc [test.tt, test.ti]
29drop table tt, ti;
30create table tt (id varchar(8) primary key,
31a int,
32b char(32),
33c char(32),
34d binary(32)) engine = tokudb;
35create table ti like tt;
36alter table ti engine=innodb;
37insert into tt values ('1',null,null,null,null);
38insert into ti values ('1',null,null,null,null);
39update tt set b='hi' where id='1';
40update ti set b='hi' where id='1';
41include/diff_tables.inc [test.tt, test.ti]
42update tt set c='there' where id='1';
43update ti set c='there' where id='1';
44include/diff_tables.inc [test.tt, test.ti]
45drop table tt, ti;
46create table tt (id varchar(8) primary key,
47a int,
48b char(32),
49c char(32),
50d binary(32)) engine = tokudb;
51create table ti like tt;
52alter table ti engine=innodb;
53insert into tt values ('1',null,null,null,null);
54insert into ti values ('1',null,null,null,null);
55update tt set b='123' where id='1';
56update ti set b='123' where id='1';
57include/diff_tables.inc [test.tt, test.ti]
58update tt set c=456 where id='1';
59update ti set c=456 where id='1';
60include/diff_tables.inc [test.tt, test.ti]
61update tt set c=789 where id=1;
62update ti set c=789 where id=1;
63include/diff_tables.inc [test.tt, test.ti]
64drop table tt, ti;
65