diff options
author | evgen@moonbone.local <> | 2006-08-02 16:44:56 +0400 |
---|---|---|
committer | evgen@moonbone.local <> | 2006-08-02 16:44:56 +0400 |
commit | 67c85a170a92d7d0620facf04b38210f22caab7e (patch) | |
tree | f3f0897ab3f3e3fe4521a2af2f85edfce317cd96 /sql/field.cc | |
parent | 6cbc44c45c0f911c5f859871224c80332517420b (diff) | |
parent | b43b2a2fe0982f0bb89ee4a996cc7729e8215cdc (diff) | |
download | mariadb-git-67c85a170a92d7d0620facf04b38210f22caab7e.tar.gz |
Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0
into moonbone.local:/work/tmp_merge-5.0-opt-mysql
Diffstat (limited to 'sql/field.cc')
-rw-r--r-- | sql/field.cc | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/sql/field.cc b/sql/field.cc index 98de224f900..921148e8f0f 100644 --- a/sql/field.cc +++ b/sql/field.cc @@ -4387,6 +4387,24 @@ Field_timestamp::Field_timestamp(char *ptr_arg, uint32 len_arg, } +Field_timestamp::Field_timestamp(bool maybe_null_arg, + const char *field_name_arg, + struct st_table *table_arg, CHARSET_INFO *cs) + :Field_str((char*) 0, 19, maybe_null_arg ? (uchar*) "": 0, 0, + NONE, field_name_arg, table_arg, cs) +{ + /* For 4.0 MYD and 4.0 InnoDB compatibility */ + flags|= ZEROFILL_FLAG | UNSIGNED_FLAG; + if (table && !table->timestamp_field && + unireg_check != NONE) + { + /* This timestamp has auto-update */ + table->timestamp_field= this; + flags|=TIMESTAMP_FLAG; + } +} + + /* Get auto-set type for TIMESTAMP field. |