|
|||||||||||
|
bk commit into 5.1 tree (anozdrin:1.2598) BUG#27610
From: Alexander Nozdrin <alik(at)mysql.com>
Date: Thu Oct 25 2007 - 07:54:42 EDT
ChangeSet@1.2598, 2007-10-25 15:54:37+04:00, anozdrin@station. +3 -0 Fix for BUG#27610: ALTER TABLE ROW_FORMAT=... does not rebuild the table. The problem was that ROW_FORMAT clause in ALTER TABLE did not trigger table reconstruction. The fix is to rebuild a table if ROW_FORMAT is specified. mysql-test/include/mix1.inc@1.58, 2007-10-25 15:54:34+04:00, anozdrin@station. +49 -0 Add a test case for BUG#27610: ALTER TABLE ROW_FORMAT=... does not rebuild the table. mysql-test/r/innodb_mysql.result@1.61, 2007-10-25 15:54:34+04:00, anozdrin@station. +34 -0 Update result file. sql/sql_table.cc@1.452, 2007-10-25 15:54:34+04:00, anozdrin@station. +1 -0 Rebuild a table if ROW_FORMAT was specified in ALTER TABLE. diff -Nrup a/mysql-test/include/mix1.inc b/mysql-test/include/mix1.inc --- a/mysql-test/include/mix1.inc 2007-10-19 02:57:40 +04:00@@ -1019,6 +1019,55 @@ SELECT * FROM t1 ORDER BY b DESC, a ASC; DROP TABLE t1; +########################################################################### # Fix for BUG#19243 "wrong LAST_INSERT_ID() after ON DUPLICATE KEY diff -Nrup a/mysql-test/r/innodb_mysql.result b/mysql-test/r/innodb_mysql.result --- a/mysql-test/r/innodb_mysql.result 2007-10-19 02:57:40 +04:00 DROP TABLE t1; + +# +# Bug#27610: ALTER TABLE ROW_FORMAT=... does not rebuild the table. +# + +# - prepare; + +DROP TABLE IF EXISTS t1; + +CREATE TABLE t1(c INT) +ENGINE = InnoDB +ROW_FORMAT = COMPACT; + +# - initial check; + +SELECT table_schema, table_name, row_format +FROM INFORMATION_SCHEMA.TABLES +WHERE table_schema = DATABASE() AND table_name = 't1'; +table_schema table_name row_format +test t1 Compact + +# - change ROW_FORMAT and check; + +ALTER TABLE t1 ROW_FORMAT = REDUNDANT; + +SELECT table_schema, table_name, row_format +FROM INFORMATION_SCHEMA.TABLES +WHERE table_schema = DATABASE() AND table_name = 't1'; +table_schema table_name row_format +test t1 Redundant + +# - that's it, cleanup. + +DROP TABLE t1; End of 5.0 tests CREATE TABLE `t2` ( `k` int(11) NOT NULL auto_increment, diff -Nrup a/sql/sql_table.cc b/sql/sql_table.cc --- a/sql/sql_table.cc 2007-10-24 11:43:12 +04:00 -- MySQL Code Commits Mailing List For list archives: http://lists.mysql.com/commits To unsubscribe: http://lists.mysql.com/commits?unsub=lists@pantek.comReceived on Thu Oct 25 07:52:27 2007 This archive was generated by hypermail 2.1.8 : Thu Jul 03 2008 - 10:40:07 EDT |
||||||||||
|
|||||||||||