mariadb/mysql-test/suite/storage_engine/alter_table_online.result
2012-07-16 06:17:56 +04:00

35 lines
1.9 KiB
Text

DROP TABLE IF EXISTS t1,t2,t3;
CREATE TABLE t1 (a <INT_COLUMN>, b <INT_COLUMN>, c <CHAR_COLUMN>) ENGINE=<STORAGE_ENGINE> <CUSTOM_TABLE_OPTIONS>;
INSERT INTO t1 (a,b,c) VALUES (1,100,'a'),(2,200,'b'),(3,300,'c');
ALTER ONLINE TABLE t1 MODIFY b <INT_COLUMN> DEFAULT 5;
ALTER ONLINE TABLE t1 CHANGE b new_name <INT_COLUMN>;
ALTER ONLINE TABLE t1 COMMENT 'new comment';
ALTER ONLINE TABLE t1 RENAME TO t2;
DROP TABLE IF EXISTS t2;
CREATE TEMPORARY TABLE t1 (a <INT_COLUMN>, b <CHAR_COLUMN>) ENGINE=<STORAGE_ENGINE> <CUSTOM_TABLE_OPTIONS>;
INSERT INTO t1 (a,b) VALUES (1,'a'),(2,'b'),(3,'c');
ALTER ONLINE TABLE t1 MODIFY b <INT_COLUMN> DEFAULT 5;
ERROR HY000: Can't execute the given 'ALTER' command as online
ALTER ONLINE TABLE t1 CHANGE b new_name <INT_COLUMN>;
ERROR HY000: Can't execute the given 'ALTER' command as online
ALTER ONLINE TABLE t1 COMMENT 'new comment';
ERROR HY000: Can't execute the given 'ALTER' command as online
ALTER ONLINE TABLE t1 RENAME TO t2;
ERROR HY000: Can't execute the given 'ALTER' command as online
DROP TABLE t1;
CREATE TABLE t1 (a <INT_COLUMN>, b <INT_COLUMN>, c <CHAR_COLUMN>) ENGINE=<STORAGE_ENGINE> <CUSTOM_TABLE_OPTIONS>;
INSERT INTO t1 (a,b,c) VALUES (1,100,'a'),(2,200,'b'),(3,300,'c');
ALTER ONLINE TABLE t1 DROP COLUMN b, ADD b <INT_COLUMN>;
ERROR HY000: Can't execute the given 'ALTER' command as online
ALTER ONLINE TABLE t1 MODIFY b BIGINT <CUSTOM_COL_OPTIONS>;
ERROR HY000: Can't execute the given 'ALTER' command as online
ALTER ONLINE TABLE t1 ENGINE=MEMORY;
ERROR HY000: Can't execute the given 'ALTER' command as online
DROP TABLE t1;
CREATE TABLE t1 (a <INT_COLUMN>, b <INT_COLUMN>, c <CHAR_COLUMN>) ENGINE=<STORAGE_ENGINE> <CUSTOM_TABLE_OPTIONS>;
ALTER ONLINE TABLE t1 ADD INDEX (b);
ERROR HY000: Can't execute the given 'ALTER' command as online
ALTER TABLE t1 ADD INDEX (b);
ALTER ONLINE TABLE t1 DROP INDEX b;
ERROR HY000: Can't execute the given 'ALTER' command as online
DROP TABLE t1;