Debian Codegraph @

mysql-test/suite/ndb_rpl/r/ndb_rpl_ui3.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 CREATE TABLE t1 (pk int primary key, uk1 int not null, uk2 int not null,
7 unique(uk1), unique(uk2)) engine=ndb;
8 insert into t1 values (1,1,1);
9 insert into t1 values (2,2,2);
10 insert into t1 values (3,3,3);
11 insert into t1 values (4,4,4);
12 insert into t1 values (5,5,5);
13 select * from t1 where uk1 in (1,2,3,4,5);
14 pk uk1 uk2
15 1 1 1
16 2 2 2
17 3 3 3
18 4 4 4
19 5 5 5
20 update t1 set uk1=uk1-1 order by pk;
21 update t1 set uk2=uk2+1 order by pk desc;
22 select * from t1 where uk1 in (0,1,2,3,4);
23 pk uk1 uk2
24 1 0 2
25 2 1 3
26 3 2 4
27 4 3 5
28 5 4 6
29 Master table contents
30 select * from t1 order by pk;
31 pk uk1 uk2
32 1 0 2
33 2 1 3
34 3 2 4
35 4 3 5
36 5 4 6
37 flush logs;
38 Slave table contents
39 select * from t1 order by pk;
40 pk uk1 uk2
41 1 0 2
42 2 1 3
43 3 2 4
44 4 3 5
45 5 4 6
46 select * from t1 where uk1 in (0,1,2,3,4);
47 pk uk1 uk2
48 1 0 2
49 2 1 3
50 3 2 4
51 4 3 5
52 5 4 6
53 drop table t1;
54 include/rpl_end.inc