blob: b98a308efb557a5d7e1073acdc0ea6466df97b7a (
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
|
SET GLOBAL wsrep_sync_wait = 15;
SET GLOBAL wsrep_sync_wait = 15;
CREATE TABLE t1 (f1 INTEGER PRIMARY KEY) ENGINE=InnoDB;
INSERT INTO t1 VALUES (1);
INSERT IGNORE INTO t1 VALUES (1), (2);
Warnings:
Warning 1062 Duplicate entry '1' for key 'PRIMARY'
SELECT * FROM t1;
f1
1
2
SELECT * FROM t1;
f1
1
2
CREATE TABLE t2 (f1 INTEGER) ENGINE=InnoDB;
INSERT INTO t2 VALUES (0), (2), (3);
INSERT IGNORE INTO t1 SELECT f1 FROM t2;
Warnings:
Warning 1062 Duplicate entry '2' for key 'PRIMARY'
SELECT * FROM t1;
f1
0
1
2
3
SELECT * FROM t1;
f1
0
1
2
3
CREATE TABLE t3 (f1 INTEGER UNIQUE) Engine=InnoDB;
INSERT INTO t3 VALUES (NULL);
INSERT IGNORE INTO t3 VALUES (1), (NULL), (2);
SELECT * FROM t3;
f1
NULL
NULL
1
2
SELECT * FROM t3;
f1
NULL
NULL
1
2
SET GLOBAL wsrep_sync_wait = (SELECT @@wsrep_sync_wait);
DROP TABLE t1;
DROP TABLE t2;
DROP TABLE t3;
SET GLOBAL wsrep_sync_wait = (SELECT @@wsrep_sync_wait);
|