diff options
author | unknown <aelkin/elkin@koti.dsl.inet.fi> | 2007-10-13 23:12:50 +0300 |
---|---|---|
committer | unknown <aelkin/elkin@koti.dsl.inet.fi> | 2007-10-13 23:12:50 +0300 |
commit | bf9eb0f0d71f741d1ab9ff5375892d93b53c01d4 (patch) | |
tree | adc8c2380bbdfc9ef9c087786ffc2ac0c79073c0 /mysql-test/r | |
parent | 1408095a117b3ebd7dab604a9f0d67a476f48aa4 (diff) | |
download | mariadb-git-bf9eb0f0d71f741d1ab9ff5375892d93b53c01d4.tar.gz |
manual merge for bug_29136, bug#29309.
mysql-test/extra/binlog_tests/mix_innodb_myisam_side_effects.test:
manual merge from 5.0
mysql-test/r/innodb.result:
results changed
mysql-test/r/multi_update.result:
results changed
mysql-test/suite/binlog/r/binlog_row_mix_innodb_myisam.result:
manual merge: results re-recorded
mysql-test/suite/binlog/r/binlog_stm_mix_innodb_myisam.result:
results changed
mysql-test/suite/manual/r/rpl_replication_delay.result:
results recorded for 5.1
mysql-test/t/innodb.test:
removing bug27716 regression test as one exists in binlog suite already.
mysql-test/t/multi_update.test:
manual merge plus refining for execution in both binlog_format.
sql/log_event.cc:
bloody manual merge;
the fact that an event is artificial is encode with setting timestamp argument to zero.
rli's last_master_timestamp won't be updated in stmt_done in such case.
sql/rpl_rli.cc:
simulation and the real fixing code.
Don't update last_master_timestamp with zero.
sql/sql_delete.cc:
manual merge
Diffstat (limited to 'mysql-test/r')
-rw-r--r-- | mysql-test/r/innodb.result | 17 | ||||
-rw-r--r-- | mysql-test/r/multi_update.result | 23 |
2 files changed, 36 insertions, 4 deletions
diff --git a/mysql-test/r/innodb.result b/mysql-test/r/innodb.result index d0b67e90afb..e1cc365f5c3 100644 --- a/mysql-test/r/innodb.result +++ b/mysql-test/r/innodb.result @@ -1086,6 +1086,19 @@ n d 1 30 2 20 drop table t1,t2; +drop table if exists t1, t2; +CREATE TABLE t1 (a int, PRIMARY KEY (a)); +CREATE TABLE t2 (a int, PRIMARY KEY (a)) ENGINE=InnoDB; +create trigger trg_del_t2 after delete on t2 for each row +insert into t1 values (1); +insert into t1 values (1); +insert into t2 values (1),(2); +delete t2 from t2; +ERROR 23000: Duplicate entry '1' for key 'PRIMARY' +select count(*) from t2 /* must be 2 as restored after rollback caused by the error */; +count(*) +2 +drop table t1, t2; create table t1 (a int, b int) engine=innodb; insert into t1 values(20,null); select t2.b, ifnull(t2.b,"this is null") from t1 as t2 left join t1 as t3 on @@ -1751,10 +1764,10 @@ Variable_name Value Innodb_page_size 16384 show status like "Innodb_rows_deleted"; Variable_name Value -Innodb_rows_deleted 70 +Innodb_rows_deleted 71 show status like "Innodb_rows_inserted"; Variable_name Value -Innodb_rows_inserted 1083 +Innodb_rows_inserted 1085 show status like "Innodb_rows_updated"; Variable_name Value Innodb_rows_updated 886 diff --git a/mysql-test/r/multi_update.result b/mysql-test/r/multi_update.result index 55e47756312..0bc01e95d2d 100644 --- a/mysql-test/r/multi_update.result +++ b/mysql-test/r/multi_update.result @@ -614,6 +614,7 @@ CREATE TABLE `t2` ( `b` int(11) default NULL, PRIMARY KEY (`a`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 ; +set @sav_binlog_format= @@session.binlog_format; set @@session.binlog_format= mixed; insert into t1 values (1,1),(2,2); insert into t2 values (1,1),(4,4); @@ -626,7 +627,7 @@ a b 4 4 show master status /* there must be the UPDATE query event */; File Position Binlog_Do_DB Binlog_Ignore_DB -master-bin.000001 197 +master-bin.000001 268 delete from t1; delete from t2; insert into t1 values (1,2),(3,4),(4,4); @@ -636,6 +637,24 @@ UPDATE t2,t1 SET t2.a=t2.b where t2.a=t1.a; ERROR 23000: Duplicate entry '4' for key 'PRIMARY' show master status /* there must be the UPDATE query event */; File Position Binlog_Do_DB Binlog_Ignore_DB -master-bin.000001 212 +master-bin.000001 283 drop table t1, t2; +set @@session.binlog_format= @sav_binlog_format; +drop table if exists t1, t2, t3; +CREATE TABLE t1 (a int, PRIMARY KEY (a)); +CREATE TABLE t2 (a int, PRIMARY KEY (a)); +CREATE TABLE t3 (a int, PRIMARY KEY (a)) ENGINE=MyISAM; +create trigger trg_del_t3 before delete on t3 for each row insert into t1 values (1); +insert into t2 values (1),(2); +insert into t3 values (1),(2); +reset master; +delete t3.* from t2,t3 where t2.a=t3.a; +ERROR 23000: Duplicate entry '1' for key 'PRIMARY' +select count(*) from t1 /* must be 1 */; +count(*) +1 +select count(*) from t3 /* must be 1 */; +count(*) +1 +drop table t1, t2, t3; end of tests |