bugfix: CREATE...SELECT lost COMMENT and VERSIONING
This commit is contained in:
parent
1d8b5524f4
commit
c0745e3730
@ -18,3 +18,24 @@ ERROR 23000: Duplicate entry '1' for key 'PRIMARY'
|
|||||||
select * from t2;
|
select * from t2;
|
||||||
ERROR 42S02: Table 'test.t2' doesn't exist
|
ERROR 42S02: Table 'test.t2' doesn't exist
|
||||||
drop table t1;
|
drop table t1;
|
||||||
|
set sql_mode='ignore_bad_table_options';
|
||||||
|
create table t1 (
|
||||||
|
f1 int invisible,
|
||||||
|
f2 int comment 'a comment',
|
||||||
|
f3 int foo="bar",
|
||||||
|
f4 int check(f4 < 10),
|
||||||
|
f5 int without system versioning
|
||||||
|
) with system versioning as select 1 as f1,2 as f2,3 as f3,4 as f4,5 as f5;
|
||||||
|
Warnings:
|
||||||
|
Warning 1911 Unknown option 'foo'
|
||||||
|
show create table t1;
|
||||||
|
Table Create Table
|
||||||
|
t1 CREATE TABLE `t1` (
|
||||||
|
`f1` int(11) INVISIBLE DEFAULT NULL,
|
||||||
|
`f2` int(11) DEFAULT NULL COMMENT 'a comment',
|
||||||
|
`f3` int(11) DEFAULT NULL `foo`='bar',
|
||||||
|
`f4` int(11) DEFAULT NULL CHECK (`f4` < 10),
|
||||||
|
`f5` int(11) DEFAULT NULL WITHOUT SYSTEM VERSIONING
|
||||||
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1 WITH SYSTEM VERSIONING
|
||||||
|
drop table t1;
|
||||||
|
set sql_mode=default;
|
||||||
|
@ -37,3 +37,17 @@ select * from t2;
|
|||||||
drop table t1;
|
drop table t1;
|
||||||
|
|
||||||
# End of 4.1 tests
|
# End of 4.1 tests
|
||||||
|
|
||||||
|
set sql_mode='ignore_bad_table_options';
|
||||||
|
create table t1 (
|
||||||
|
f1 int invisible,
|
||||||
|
f2 int comment 'a comment',
|
||||||
|
f3 int foo="bar",
|
||||||
|
f4 int check(f4 < 10),
|
||||||
|
f5 int without system versioning
|
||||||
|
) with system versioning as select 1 as f1,2 as f2,3 as f3,4 as f4,5 as f5;
|
||||||
|
show create table t1;
|
||||||
|
drop table t1;
|
||||||
|
set sql_mode=default;
|
||||||
|
|
||||||
|
# End of 10.4 tests
|
||||||
|
@ -10768,6 +10768,9 @@ Column_definition::redefine_stage1_common(const Column_definition *dup_field,
|
|||||||
vcol_info= dup_field->vcol_info;
|
vcol_info= dup_field->vcol_info;
|
||||||
invisible= dup_field->invisible;
|
invisible= dup_field->invisible;
|
||||||
check_constraint= dup_field->check_constraint;
|
check_constraint= dup_field->check_constraint;
|
||||||
|
comment= dup_field->comment;
|
||||||
|
option_list= dup_field->option_list;
|
||||||
|
versioning= dup_field->versioning;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user