blob: f9794df3be7b4e8d36f36834e928b4e66a6ae19d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
|
include/master-slave.inc
[connection master]
select @@rpl_semi_sync_master_enabled;
@@rpl_semi_sync_master_enabled
0
connection slave;
select @@rpl_semi_sync_slave_enabled;
@@rpl_semi_sync_slave_enabled
0
show status like "rpl_semi_sync_slave_status";
Variable_name Value
Rpl_semi_sync_slave_status OFF
connection master;
drop table if exists t1;
Warnings:
Note 1051 Unknown table 'test.t1'
create table t1(a varchar(100),b int);
set @@session.sql_mode=pipes_as_concat;
insert into t1 values('My'||'SQL', 1);
set @@session.sql_mode=default;
insert into t1 values('1'||'2', 2);
select * from t1 where b<3 order by a;
a b
1 2
MySQL 1
connection slave;
select * from t1 where b<3 order by a;
a b
1 2
MySQL 1
connection master;
set @@session.sql_mode=ignore_space;
insert into t1 values(password ('MySQL'), 3);
set @@session.sql_mode=ansi_quotes;
create table "t2" ("a" int);
drop table t1, t2;
set @@session.sql_mode=default;
create table t1(a int auto_increment primary key);
create table t2(b int, a int);
set @@session.sql_auto_is_null=1;
insert into t1 values(null);
insert into t2 select 1,a from t1 where a is null;
set @@session.sql_auto_is_null=0;
insert into t1 values(null);
insert into t2 select 2,a from t1 where a is null;
select * from t2 order by b;
b a
1 1
connection slave;
select * from t2 order by b;
b a
1 1
connection master;
drop table t1,t2;
connection slave;
connection master;
CREATE TABLE t1 (
`id` int(11) NOT NULL auto_increment,
`data` varchar(100),
PRIMARY KEY (`id`)
) ENGINE=MyISAM;
INSERT INTO t1(data) VALUES(SESSION_USER());
connection slave;
SELECT length(data) < 100 FROM t1;
length(data) < 100
1
connection master;
drop table t1;
include/rpl_end.inc
|