Commit e29c74c2 authored by Sergei Golubchik's avatar Sergei Golubchik

Fix a first timestamp column in the sql-based table discovery

parent a14b7341
......@@ -2136,6 +2136,7 @@ int TABLE_SHARE::init_from_sql_statement_string(THD *thd, bool write,
if (tabledef_version.str)
thd->lex->create_info.tabledef_version= tabledef_version;
promote_first_timestamp_column(&thd->lex->alter_info.create_list);
file= mysql_create_frm_image(thd, db.str, table_name.str,
&thd->lex->create_info, &thd->lex->alter_info,
C_ORDINARY_CREATE, &unused1, &unused2, &frm);
......
......@@ -123,7 +123,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE t1 (
a int(11) NOT NULL DEFAULT '5',
b timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
b timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
c tinyblob,
d decimal(5,2) DEFAULT NULL,
e varchar(30) CHARACTER SET ascii DEFAULT NULL,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment