Debian Codegraph @

mysql-test/suite/merge/alter_table.result

raw
1 #
2 # BUG#6236 - ALTER TABLE MODIFY should set implicit NOT NULL on PK columns
3 #
4 create table t1 ( a varchar(10) not null primary key ) engine=myisam;
5 create table t2 ( a varchar(10) not null primary key ) engine=merge union=(t1);
6 flush tables;
7 alter table t1 modify a varchar(10);
8 show create table t2;
9 Table Create Table
10 t2 CREATE TABLE `t2` (
11 `a` varchar(10) NOT NULL,
12 PRIMARY KEY (`a`)
13 ) ENGINE=MRG_MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_uca1400_ai_ci UNION=(`t1`)
14 flush tables;
15 alter table t1 modify a varchar(10) not null;
16 show create table t2;
17 Table Create Table
18 t2 CREATE TABLE `t2` (
19 `a` varchar(10) NOT NULL,
20 PRIMARY KEY (`a`)
21 ) ENGINE=MRG_MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_uca1400_ai_ci UNION=(`t1`)
22 drop table if exists t1, t2;