summaryrefslogtreecommitdiff
path: root/mysql-test/r/innodb.result
diff options
context:
space:
mode:
authorunknown <osku@127.(none)>2005-09-23 11:20:34 +0300
committerunknown <osku@127.(none)>2005-09-23 11:20:34 +0300
commit6fbbb1d5be323d08e622a018001453b49d8a0248 (patch)
treece6530b960229fcd168e9501f71caeccf13beec7 /mysql-test/r/innodb.result
parentd2fc3bd4245f8c212046e88151da4a66d1b048b3 (diff)
downloadmariadb-git-6fbbb1d5be323d08e622a018001453b49d8a0248.tar.gz
InnoDB: Fix bug #13315, index columns having a maximum length of 767.
innobase/data/data0data.c: Adapt to DICT_MAX_COL_PREFIX_LEN rename. innobase/dict/dict0dict.c: Adapt to DICT_MAX_COL_PREFIX_LEN rename. innobase/include/dict0mem.h: Rename DICT_MAX_COL_PREFIX_LEN to DICT_MAX_INDEX_COL_LEN. innobase/include/row0mysql.h: Add field_lengths parameter to row_create_index_for_mysql. innobase/rem/rem0rec.c: Adapt to DICT_MAX_COL_PREFIX_LEN rename. innobase/row/row0mysql.c: Add field_lengths parameter to row_create_index_for_mysql and use it to check for too long index columns. mysql-test/r/innodb.result: New tests. mysql-test/t/innodb.test: New tests. sql/ha_innodb.cc: Create temporary field_lengths buffer and pass it to row_create_index_for_mysql.
Diffstat (limited to 'mysql-test/r/innodb.result')
-rw-r--r--mysql-test/r/innodb.result34
1 files changed, 34 insertions, 0 deletions
diff --git a/mysql-test/r/innodb.result b/mysql-test/r/innodb.result
index ffc4ab08ab4..8d44a2a12ab 100644
--- a/mysql-test/r/innodb.result
+++ b/mysql-test/r/innodb.result
@@ -2559,3 +2559,37 @@ FOREIGN KEY (b) REFERENCES test.t1(id)
) ENGINE=InnoDB;
Got one of the listed errors
DROP TABLE t1;
+create table t1 (col1 varchar(2000), index (col1(767)))
+character set = latin1 engine = innodb;
+create table t2 (col1 char(255), index (col1))
+character set = latin1 engine = innodb;
+create table t3 (col1 binary(255), index (col1))
+character set = latin1 engine = innodb;
+create table t4 (col1 varchar(767), index (col1))
+character set = latin1 engine = innodb;
+create table t5 (col1 varchar(767) primary key)
+character set = latin1 engine = innodb;
+create table t6 (col1 varbinary(767) primary key)
+character set = latin1 engine = innodb;
+create table t7 (col1 text, index(col1(767)))
+character set = latin1 engine = innodb;
+create table t8 (col1 blob, index(col1(767)))
+character set = latin1 engine = innodb;
+create table t9 (col1 varchar(512), col2 varchar(512), index(col1, col2))
+character set = latin1 engine = innodb;
+drop table t1, t2, t3, t4, t5, t6, t7, t8, t9;
+create table t1 (col1 varchar(768), index (col1))
+character set = latin1 engine = innodb;
+ERROR HY000: Can't create table './test/t1.frm' (errno: 139)
+create table t2 (col1 varchar(768) primary key)
+character set = latin1 engine = innodb;
+ERROR HY000: Can't create table './test/t2.frm' (errno: 139)
+create table t3 (col1 varbinary(768) primary key)
+character set = latin1 engine = innodb;
+ERROR HY000: Can't create table './test/t3.frm' (errno: 139)
+create table t4 (col1 text, index(col1(768)))
+character set = latin1 engine = innodb;
+ERROR HY000: Can't create table './test/t4.frm' (errno: 139)
+create table t5 (col1 blob, index(col1(768)))
+character set = latin1 engine = innodb;
+ERROR HY000: Can't create table './test/t5.frm' (errno: 139)