~ubuntu-branches/ubuntu/trusty/mysql-5.6/trusty

« back to all changes in this revision

Viewing changes to mysql-test/suite/engines/funcs/t/in_multicolumn_string_pk_constraint_error.test

  • Committer: Package Import Robot
  • Author(s): James Page
  • Date: 2014-02-12 11:54:27 UTC
  • Revision ID: package-import@ubuntu.com-20140212115427-oq6tfsqxl1wuwehi
Tags: upstream-5.6.15
ImportĀ upstreamĀ versionĀ 5.6.15

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
--disable_warnings
 
2
DROP TABLE IF EXISTS t1;
 
3
--enable_warnings
 
4
CREATE TABLE t1(c1 CHAR(10) NOT NULL, c2 CHAR(10) NOT NULL, c3 CHAR(10) NOT NULL, PRIMARY KEY(c1,c2,c3));
 
5
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
 
6
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
 
7
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','abc');
 
8
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc');
 
9
INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc');
 
10
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def');
 
11
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
 
12
--error ER_DUP_ENTRY
 
13
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
 
14
--error ER_DUP_ENTRY
 
15
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
 
16
--error ER_DUP_ENTRY
 
17
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
 
18
--sorted_result
 
19
SELECT * FROM t1;
 
20
DROP TABLE t1;
 
21
CREATE TABLE t1(c1 VARCHAR(10) NOT NULL, c2 VARCHAR(10) NOT NULL, c3 VARCHAR(10) NOT NULL, PRIMARY KEY(c1,c2,c3));
 
22
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
 
23
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
 
24
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','abc');
 
25
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc');
 
26
INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc');
 
27
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def');
 
28
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
 
29
--error ER_DUP_ENTRY
 
30
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
 
31
--error ER_DUP_ENTRY
 
32
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
 
33
--error ER_DUP_ENTRY
 
34
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
 
35
--sorted_result
 
36
SELECT hex(c1),hex(c2),hex(c3) FROM t1;
 
37
DROP TABLE t1;
 
38
CREATE TABLE t1(c1 BINARY(10) NOT NULL, c2 BINARY(10) NOT NULL, c3 BINARY(10) NOT NULL, PRIMARY KEY(c1,c2,c3));
 
39
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
 
40
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
 
41
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','abc');
 
42
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc');
 
43
INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc');
 
44
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def');
 
45
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
 
46
# Bug#52430 
 
47
--error ER_DUP_ENTRY
 
48
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
 
49
--error ER_DUP_ENTRY
 
50
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
 
51
--error ER_DUP_ENTRY
 
52
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
 
53
--sorted_result
 
54
SELECT hex(c1),hex(c2),hex(c3) FROM t1;
 
55
DROP TABLE t1;
 
56
CREATE TABLE t1(c1 VARBINARY(10) NOT NULL, c2 VARBINARY(10) NOT NULL, c3 VARBINARY(10) NOT NULL, PRIMARY KEY(c1,c2,c3));
 
57
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
 
58
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
 
59
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','abc');
 
60
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc');
 
61
INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc');
 
62
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def');
 
63
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
 
64
--error ER_DUP_ENTRY
 
65
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
 
66
--error ER_DUP_ENTRY
 
67
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
 
68
--error ER_DUP_ENTRY
 
69
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
 
70
--sorted_result
 
71
SELECT * FROM t1;
 
72
DROP TABLE t1;
 
73