mirror of
https://github.com/MariaDB/server.git
synced 2025-01-22 23:04:20 +01:00
6509b5b48a
Slave starts accepting and handling rows of master's tables which have more columns. The most important part of implementation is how to caclulate the amount of bytes to skip for unknown by slave column. To solve that issue this WL adopts results of WL#3228 which introduces an addon to table_map event that carries the necessary part of information about sizes of data of columns. mysql-test/extra/rpl_tests/rpl_extraMaster_Col.test@stripped, 2007-07-26 21:31:54-04:00, cbell@mysql_cab_desk. +393 -0 WL#3915 master's cols > slave basic tests checking altering and skipping extra fields by slave. The fields can be of any possible types.
373 lines
12 KiB
Text
373 lines
12 KiB
Text
stop slave;
|
||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||
reset master;
|
||
reset slave;
|
||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||
start slave;
|
||
CREATE TABLE t1 (f1 INT, f2 INT, f3 INT PRIMARY KEY, f4 CHAR(20),
|
||
/* extra */
|
||
f5 FLOAT DEFAULT '2.00',
|
||
f6 CHAR(4) DEFAULT 'TEST',
|
||
f7 INT DEFAULT '0',
|
||
f8 TEXT,
|
||
f9 LONGBLOB,
|
||
f10 BIT(63),
|
||
f11 VARBINARY(64))
|
||
ENGINE='NDB';
|
||
alter table t1 drop f5, drop f6, drop f7, drop f8, drop f9, drop f10, drop f11;
|
||
INSERT into t1 values (1, 1, 1, 'first', 1.0, 'yksi', 1, 'lounge of happiness', 'very fat blob', b'01010101010101', 0x123456);
|
||
INSERT into t1 values (2, 2, 2, 'second', 2.0, 'kaks', 2, 'got stolen from the paradise', 'very fat blob', b'01010101010101', 0x123456), (3, 3, 3, 'third', 3.0, 'kolm', 3, 'got stolen from the paradise', 'very fat blob', b'01010101010101', 0x123456);
|
||
update t1 set f4= 'next' where f1=1;
|
||
delete from t1 where f1=1;
|
||
select * from t1 order by f3;
|
||
f1 f2 f3 f4 f5 f6 f7 f8 f9 f10 f11
|
||
2 2 2 second 2 kaks 2 got stolen from the paradise very fat blob |