List:Commits« Previous MessageNext Message »
From:marko.makela Date:April 21 2010 10:27am
Subject:bzr commit into mysql-5.1-innodb branch (marko.makela:3412) Bug#50495
View as plain text  
#At file:///home/marko/innobase/dev/mysql/5.1-innodb/ based on revid:marko.makela@strippeddgvuqh96qq

 3412 Marko Mäkelä	2010-04-21
      dict_create_index_step(): Be strict about DYNAMIC and COMPRESSED tables.
      Bug #50495 is about REDUNDANT and COMPACT tables, after all.

    modified:
      mysql-test/suite/innodb_plugin/r/innodb-zip.result
      mysql-test/suite/innodb_plugin/t/innodb-zip.test
      storage/innodb_plugin/ChangeLog
      storage/innodb_plugin/dict/dict0crea.c
=== modified file 'mysql-test/suite/innodb_plugin/r/innodb-zip.result'
--- a/mysql-test/suite/innodb_plugin/r/innodb-zip.result	2010-04-21 09:40:32 +0000
+++ b/mysql-test/suite/innodb_plugin/r/innodb-zip.result	2010-04-21 10:27:23 +0000
@@ -127,12 +127,6 @@ CREATE TABLE t1(
 c TEXT NOT NULL, d TEXT NOT NULL,
 PRIMARY KEY (c(767),d(767)))
 ENGINE=InnoDB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1 CHARSET=ASCII;
-DROP TABLE t1;
-SET SESSION innodb_strict_mode = on;
-CREATE TABLE t1(
-c TEXT NOT NULL, d TEXT NOT NULL,
-PRIMARY KEY (c(767),d(767)))
-ENGINE=InnoDB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1 CHARSET=ASCII;
 ERROR 42000: Row size too large. The maximum row size for the used table type, not counting BLOBs, is 8126. You have to change some columns to TEXT or BLOBs
 CREATE TABLE t1(
 c TEXT NOT NULL, d TEXT NOT NULL,

=== modified file 'mysql-test/suite/innodb_plugin/t/innodb-zip.test'
--- a/mysql-test/suite/innodb_plugin/t/innodb-zip.test	2010-04-21 09:40:32 +0000
+++ b/mysql-test/suite/innodb_plugin/t/innodb-zip.test	2010-04-21 10:27:23 +0000
@@ -85,14 +85,9 @@ SELECT table_schema, table_name, row_for
 FROM information_schema.tables WHERE engine='innodb';
 drop table t1,t2;
 
-# The following should not fail in non-strict mode. (Bug #50945)
+# The following should fail in non-strict mode too.
+# (The fix of Bug #50945 only affects REDUNDANT and COMPACT tables.)
 SET SESSION innodb_strict_mode = off;
-CREATE TABLE t1(
-	c TEXT NOT NULL, d TEXT NOT NULL,
-	PRIMARY KEY (c(767),d(767)))
-ENGINE=InnoDB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1 CHARSET=ASCII;
-DROP TABLE t1;
-SET SESSION innodb_strict_mode = on;
 --error ER_TOO_BIG_ROWSIZE
 CREATE TABLE t1(
 	c TEXT NOT NULL, d TEXT NOT NULL,

=== modified file 'storage/innodb_plugin/ChangeLog'
--- a/storage/innodb_plugin/ChangeLog	2010-04-21 09:50:33 +0000
+++ b/storage/innodb_plugin/ChangeLog	2010-04-21 10:27:23 +0000
@@ -9,7 +9,7 @@
 	Fix Bug#50495 'Row size too large' for plugin, but works for
 	built-in InnoDB
 	Only check the record size at index creation time when
-	innodb_strict_mode is set.
+	innodb_strict_mode is set or when ROW_FORMAT is DYNAMIC or COMPRESSED.
 
 2010-04-20	The InnoDB Team
 

=== modified file 'storage/innodb_plugin/dict/dict0crea.c'
--- a/storage/innodb_plugin/dict/dict0crea.c	2010-04-20 11:42:22 +0000
+++ b/storage/innodb_plugin/dict/dict0crea.c	2010-04-21 10:27:23 +0000
@@ -1105,8 +1105,11 @@ dict_create_index_step(
 
 		dulint	index_id = node->index->id;
 
-		err = dict_index_add_to_cache(node->table, node->index,
-					      FIL_NULL, trx_is_strict(trx));
+		err = dict_index_add_to_cache(
+			node->table, node->index, FIL_NULL,
+			trx_is_strict(trx)
+			|| dict_table_get_format(node->table)
+			>= DICT_TF_FORMAT_ZIP);
 
 		node->index = dict_index_get_if_in_cache_low(index_id);
 		ut_a(!node->index == (err != DB_SUCCESS));

Attachment: [text/bzr-bundle] bzr/marko.makela@oracle.com-20100421102723-0i80uezbyu0ekj5d.bundle
Thread
bzr commit into mysql-5.1-innodb branch (marko.makela:3412) Bug#50495marko.makela21 Apr