mirror of
https://github.com/MariaDB/server.git
synced 2025-01-23 07:14:17 +01:00
f66e34d0d7
git-svn-id: file:///svn/mysql/tests/mysql-test@55031 c7de825b-a66e-492c-adef-691d508d4ae1
31 lines
No EOL
897 B
Text
31 lines
No EOL
897 B
Text
# test that varbinary expansion + default change works
|
|
|
|
--disable_warnings
|
|
DROP TABLE IF EXISTS t;
|
|
--enable_warnings
|
|
|
|
SET SESSION TOKUDB_DISABLE_SLOW_ALTER=ON;
|
|
|
|
CREATE TABLE t (a VARBINARY(100) NOT NULL DEFAULT '', b VARBINARY(256) NOT NULL DEFAULT '') ENGINE=TokuDB;
|
|
SHOW CREATE TABLE t;
|
|
|
|
ALTER TABLE t CHANGE COLUMN a a VARBINARY(255) NOT NULL DEFAULT 'a';
|
|
SHOW CREATE TABLE t;
|
|
|
|
ALTER TABLE t CHANGE COLUMN a a VARBINARY(256) NOT NULL DEFAULT 'b';
|
|
SHOW CREATE TABLE t;
|
|
|
|
# no shrinkage
|
|
--replace_regex /MariaDB/XYZ/ /MySQL/XYZ/
|
|
--error ER_UNSUPPORTED_EXTENSION
|
|
ALTER TABLE t CHANGE COLUMN b b VARBINARY(255) NOT NULL DEFAULT 'c';
|
|
|
|
ALTER TABLE t CHANGE COLUMN b b VARBINARY(1024) NOT NULL DEFAULT 'd';
|
|
SHOW CREATE TABLE t;
|
|
|
|
# no shrinkage
|
|
--replace_regex /MariaDB/XYZ/ /MySQL/XYZ/
|
|
--error ER_UNSUPPORTED_EXTENSION
|
|
ALTER TABLE t CHANGE COLUMN b b VARBINARY(256) NOT NULL DEFAULT 'e';
|
|
|
|
DROP TABLE t; |