Debian Codegraph @

mysql-test/suite/rpl/r/rpl_row_jsondiff_multitables.result

raw
1 include/master-slave.inc
2 Warnings:
3 Note #### Sending passwords in plain text without SSL/TLS is extremely insecure.
4 Note #### Storing MySQL user name or password information in the connection metadata repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START REPLICA; see the 'START REPLICA Syntax' in the MySQL Manual for more information.
5 [connection master]
6 ######## Configure ########
7 SET @@SESSION.BINLOG_ROW_IMAGE = 'MINIMAL';
8 SET @@SESSION.BINLOG_ROW_VALUE_OPTIONS = 'PARTIAL_JSON';
9 [connection slave]
10 SET @old_binlog_row_image= @@GLOBAL.BINLOG_ROW_IMAGE;
11 SET @old_binlog_row_value_options= @@GLOBAL.BINLOG_ROW_VALUE_OPTIONS;
12 SET @@GLOBAL.BINLOG_ROW_IMAGE = 'MINIMAL';
13 SET @@GLOBAL.BINLOG_ROW_VALUE_OPTIONS = 'PARTIAL_JSON';
14 include/stop_slave.inc
15 include/start_slave.inc
16 ######## Initialize ########
17 [connection master]
18 CREATE TABLE t1 (i INT PRIMARY KEY, j JSON);
19 CREATE TABLE t2 (i INT PRIMARY KEY, j JSON);
20 INSERT INTO t1 VALUES (1, '["a-1", "b-1"]');
21 INSERT INTO t2 VALUES (1, '["c-1", "d-1"]');
22 include/sync_slave_sql_with_master.inc
23 ######## Test ########
24 [connection master]
25 # Both tables with partial update
26 UPDATE t1, t2 SET t1.j= JSON_SET(t1.j, '$[0]', 'a-2'),
27 t2.j= JSON_SET(t2.j, '$[0]', 'c-2');
28 include/sync_slave_sql_with_master.inc
29 [connection master]
30 include/diff_tables.inc [master:t1, slave:t1]
31 include/diff_tables.inc [master:t2, slave:t2]
32 # First table partial update, second table full update
33 UPDATE t1, t2 SET t1.j= JSON_SET(t1.j, '$[0]', 'a-3'),
34 t2.j= '["c-3", "d-1"]';
35 include/sync_slave_sql_with_master.inc
36 [connection master]
37 include/diff_tables.inc [master:t1, slave:t1]
38 include/diff_tables.inc [master:t2, slave:t2]
39 # First table full update, second table partial update
40 UPDATE t1, t2 SET t1.j= '["a-4", "b-1"]',
41 t2.j= JSON_SET(t2.j, '$[0]', 'c-4');
42 include/sync_slave_sql_with_master.inc
43 [connection master]
44 include/diff_tables.inc [master:t1, slave:t1]
45 include/diff_tables.inc [master:t2, slave:t2]
46 # Both tables with full update
47 UPDATE t1, t2 SET t1.j= '["a-5", "b-1"]',
48 t2.j= '["c-5", "d-1"]';
49 include/sync_slave_sql_with_master.inc
50 [connection master]
51 include/diff_tables.inc [master:t1, slave:t1]
52 include/diff_tables.inc [master:t2, slave:t2]
53 ######## Clean up ########
54 DROP TABLE t1, t2;
55 include/sync_slave_sql_with_master.inc
56 SET @@GLOBAL.BINLOG_ROW_VALUE_OPTIONS= @old_binlog_row_value_options;
57 SET @@GLOBAL.BINLOG_ROW_IMAGE= @old_binlog_row_image;
58 include/rpl_end.inc