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