diff options
author | unknown <gluh@gluh.mysql.r18.ru> | 2004-12-07 15:18:13 +0300 |
---|---|---|
committer | unknown <gluh@gluh.mysql.r18.ru> | 2004-12-07 15:18:13 +0300 |
commit | 301582c18944e01d86d63ca1f0b63ac8bf596f9d (patch) | |
tree | e502af7d48286d5f7b98157cfbdfd7542917df4f /mysql-test | |
parent | 31099d116bb801e43e261bc4576023c846ab09c7 (diff) | |
parent | 9f48eedb4e2251dbc30019ad012cb808385072ab (diff) | |
download | mariadb-git-301582c18944e01d86d63ca1f0b63ac8bf596f9d.tar.gz |
Merge sgluhov@bk-internal.mysql.com:/home/bk/mysql-4.1
into gluh.mysql.r18.ru:/home/gluh/MySQL-BUGS/mysql-4.1.6840
Diffstat (limited to 'mysql-test')
-rw-r--r-- | mysql-test/r/type_enum.result | 8 | ||||
-rw-r--r-- | mysql-test/t/type_enum.test | 15 |
2 files changed, 22 insertions, 1 deletions
diff --git a/mysql-test/r/type_enum.result b/mysql-test/r/type_enum.result index 2ccf32367fb..e5239dcf769 100644 --- a/mysql-test/r/type_enum.result +++ b/mysql-test/r/type_enum.result @@ -1737,3 +1737,11 @@ def test t1 t1 c c 254 3 0 Y 384 0 8 a b c Y NULL NULL drop table t1; +create table t1 (a enum('x','y') default 'x'); +alter table t1 alter a set default 'z'; +ERROR 42000: Invalid default value for 'a' +drop table t1; +create table t1 (a set('x','y') default 'x'); +alter table t1 alter a set default 'z'; +ERROR 42000: Invalid default value for 'a' +drop table t1; diff --git a/mysql-test/t/type_enum.test b/mysql-test/t/type_enum.test index 3a5b12b91e4..6b2183df069 100644 --- a/mysql-test/t/type_enum.test +++ b/mysql-test/t/type_enum.test @@ -111,5 +111,18 @@ alter table t1 add b set ('Y','N') CHARACTER SET utf8 COLLATE utf8_bin; alter table t1 add c enum ('Y','N') CHARACTER SET utf8 COLLATE utf8_bin; --enable_metadata select * from t1; ---disable metadata +--disable_metadata +drop table t1; + +# +# Bug #6840 Default value is not checked in ALTER column SET DEFAULT 'x' +# +create table t1 (a enum('x','y') default 'x'); +--error 1067 +alter table t1 alter a set default 'z'; +drop table t1; + +create table t1 (a set('x','y') default 'x'); +--error 1067 +alter table t1 alter a set default 'z'; drop table t1; |