Commit 65418527 authored by unknown's avatar unknown

BUG#28722 (Multi-engine statements on has_own_binlogging engine):

Test fixes resulting from changed semantics.


mysql-test/extra/rpl_tests/rpl_row_UUID.test:
  Using same engine throughout to prevent NDB tests from failing.
mysql-test/r/binlog_multi_engine.result:
  Result change.
mysql-test/r/ndb_read_multi_range.result:
  Result change.
mysql-test/r/ndb_trigger.result:
  Result change.
mysql-test/r/rpl_ndb_UUID.result:
  Result change.
mysql-test/r/rpl_row_UUID.result:
  Result change.
mysql-test/t/binlog_multi_engine.test:
  Removing garbage.
mysql-test/t/ndb_read_multi_range.test:
  Using ndbcluster for table used inside trigger.
mysql-test/t/ndb_trigger.test:
  Using ndbcluster for table used inside trigger.
parent 10b10375
......@@ -41,7 +41,7 @@ end|
delimiter ;|
# test both in SELECT and in INSERT
select fn1(0);
create table t2 (a int);
eval create table t2 (a int) engine=$engine_type;
insert into t2 values(fn1(2));
sync_slave_with_master;
......
......@@ -11,7 +11,6 @@ START TRANSACTION;
INSERT INTO t1n VALUES (1,1), (1,2), (2,1), (2,2);
UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f;
UPDATE t1n, t1b SET e = 2, b = 3 WHERE f = c;
ERROR HY000: Binary logging not possible. Message: Statement-based format required for this statement, but not allowed by this combination of engines
COMMIT;
TRUNCATE t1m;
TRUNCATE t1b;
......@@ -49,18 +48,6 @@ ERROR HY000: Binary logging not possible. Message: Statement cannot be written a
TRUNCATE t1m;
TRUNCATE t1b;
TRUNCATE t1n;
SET SESSION BINLOG_FORMAT=ROW;
INSERT INTO t1m VALUES (1,1), (1,2), (2,1), (2,2);
INSERT INTO t1b VALUES (1,1), (1,2), (2,1), (2,2);
ERROR HY000: Binary logging not possible. Message: Row-based format required for this statement, but not allowed by this combination of engines
INSERT INTO t1n VALUES (1,1), (1,2), (2,1), (2,2);
UPDATE t1m, t1b SET m = 2, b = 3 WHERE n = c;
ERROR HY000: Binary logging not possible. Message: Row-based format required for this statement, but not allowed by this combination of engines
UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f;
ERROR HY000: Binary logging not possible. Message: Statement cannot be written atomically since more than one engine involved and at least one engine is self-logging
UPDATE t1n, t1b SET e = 2, b = 3 WHERE f = c;
ERROR HY000: Binary logging not possible. Message: Row-based format required for this statement, but not allowed by this combination of engines
DROP TABLE t1m, t1b, t1n;
show binlog events from <binlog_start>;
Log_name Pos Event_type Server_id End_log_pos Info
master-bin.000001 # Query # # use `test`; INSERT INTO t1m VALUES (1,1), (1,2), (2,1), (2,2)
......@@ -84,8 +71,10 @@ ERROR HY000: Binary logging not possible. Message: Row-based format required for
INSERT INTO t1n VALUES (1,1), (1,2), (2,1), (2,2);
UPDATE t1m, t1b SET m = 2, b = 3 WHERE n = c;
ERROR HY000: Binary logging not possible. Message: Row-based format required for this statement, but not allowed by this combination of engines
UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f;
ERROR HY000: Binary logging not possible. Message: Statement cannot be written atomically since more than one engine involved and at least one engine is self-logging
UPDATE t1n, t1b SET e = 2, b = 3 WHERE f = c;
ERROR HY000: Binary logging not possible. Message: Statement cannot be logged to the binary log in row-based nor statement-based format
ERROR HY000: Binary logging not possible. Message: Row-based format required for this statement, but not allowed by this combination of engines
show binlog events from <binlog_start>;
Log_name Pos Event_type Server_id End_log_pos Info
master-bin.000001 # Table_map # # table_id: # (test.t1m)
......
......@@ -451,7 +451,7 @@ CREATE TABLE t2 (
var1 int(2) NOT NULL,
var2 int(2) NOT NULL,
PRIMARY KEY (var1)
) ENGINE=MyISAM DEFAULT CHARSET=ascii CHECKSUM=1;
) ENGINE=ndbcluster DEFAULT CHARSET=ascii CHECKSUM=1;
CREATE TRIGGER testtrigger
AFTER UPDATE ON t1 FOR EACH ROW BEGIN
REPLACE INTO t2 SELECT * FROM t1 WHERE t1.var1 = NEW.var1;END|
......
drop table if exists t1, t2, t3, t4, t5;
create table t1 (id int primary key, a int not null, b decimal (63,30) default 0) engine=ndb;
create table t2 (op char(1), a int not null, b decimal (63,30));
create table t3 select 1 as i;
create table t2 (op char(1), a int not null, b decimal (63,30)) engine=ndb;
create table t3 engine=ndb select 1 as i;
create table t4 (a int not null primary key, b int) engine=ndb;
create table t5 (a int not null primary key, b int) engine=ndb;
create trigger t1_bu before update on t1 for each row
......
......@@ -24,7 +24,7 @@ end|
select fn1(0);
fn1(0)
0
create table t2 (a int);
create table t2 (a int) engine=NDB;
insert into t2 values(fn1(2));
SHOW CREATE TABLE test.t1;
Table Create Table
......
......@@ -24,7 +24,7 @@ end|
select fn1(0);
fn1(0)
0
create table t2 (a int);
create table t2 (a int) engine=myisam;
insert into t2 values(fn1(2));
SHOW CREATE TABLE test.t1;
Table Create Table
......
......@@ -54,7 +54,6 @@ UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f;
#UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f;
>>>>>>>
error ER_BINLOG_LOGGING_IMPOSSIBLE;
UPDATE t1n, t1b SET e = 2, b = 3 WHERE f = c;
......
......@@ -286,7 +286,7 @@ CREATE TABLE t2 (
var1 int(2) NOT NULL,
var2 int(2) NOT NULL,
PRIMARY KEY (var1)
) ENGINE=MyISAM DEFAULT CHARSET=ascii CHECKSUM=1;
) ENGINE=ndbcluster DEFAULT CHARSET=ascii CHECKSUM=1;
DELIMITER |;
......
......@@ -19,8 +19,8 @@ drop table if exists t1, t2, t3, t4, t5;
--enable_warnings
create table t1 (id int primary key, a int not null, b decimal (63,30) default 0) engine=ndb;
create table t2 (op char(1), a int not null, b decimal (63,30));
create table t3 select 1 as i;
create table t2 (op char(1), a int not null, b decimal (63,30)) engine=ndb;
create table t3 engine=ndb select 1 as i;
create table t4 (a int not null primary key, b int) engine=ndb;
create table t5 (a int not null primary key, b int) engine=ndb;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment