1
0
mirror of https://github.com/MariaDB/server.git synced 2026-01-06 05:22:24 +03:00

Manual merge from mysql-5.5-bugteam.

This commit is contained in:
Ramil Kalimullin
2010-11-22 14:47:28 +03:00
344 changed files with 10351 additions and 14742 deletions

View File

@@ -607,3 +607,24 @@ SET SESSION sql_mode = 'NO_ZERO_DATE';
OPTIMIZE TABLE t1;
SET SESSION sql_mode = @old_mode;
DROP TABLE t1;
--echo #
--echo # Bug#57985 "ONLINE/FAST ALTER PARTITION can fail and leave the
--echo # table unusable".
--echo #
--disable_warnings
DROP TABLE IF EXISTS t1;
--enable_warnings
CREATE TABLE t1 (a bigint not null, b int not null, PRIMARY KEY (a))
ENGINE = InnoDB PARTITION BY KEY(a) PARTITIONS 2;
INSERT INTO t1 values (0,1), (1,2);
--echo # The below ALTER should fail. It should leave the
--echo # table in its original, non-corrupted, usable state.
--error ER_UNIQUE_KEY_NEED_ALL_FIELDS_IN_PF
ALTER TABLE t1 ADD UNIQUE KEY (b);
--echo # The below statements should succeed, as ALTER should
--echo # have left table intact.
SHOW CREATE TABLE t1;
SELECT * FROM t1;
DROP TABLE t1;