diff options
author | unknown <holyfoot/hf@mysql.com/deer.(none)> | 2006-10-25 20:14:39 +0500 |
---|---|---|
committer | unknown <holyfoot/hf@mysql.com/deer.(none)> | 2006-10-25 20:14:39 +0500 |
commit | 01a0be193d8344e1b20c366b30a7ca75a0a9bd44 (patch) | |
tree | 248f0c5b988b23156208cb6f1d2014539218eb9d /sql/field.cc | |
parent | 3f4964394c0f3bb75a4c02549b70b728aa1ddd90 (diff) | |
download | mariadb-git-01a0be193d8344e1b20c366b30a7ca75a0a9bd44.tar.gz |
bug #19491 (CAST do DATETIME wrong result)
mysql-test/r/type_datetime.result:
result fixed
mysql-test/r/type_newdecimal.result:
result fixed
mysql-test/t/type_datetime.test:
testcase
mysql-test/t/type_newdecimal.test:
testcase
sql/field.cc:
Field_new_decimal::store_time implemented
sql/field.h:
Field_new_decimal::store_time added
sql/item.cc:
auxiliary methods implemented to operate with datatimes
sql/item.h:
auxiliary methods declared in Item to operate with datatimes
sql/item_timefunc.cc:
Item_date::save_in_field old implementation removed
sql/item_timefunc.h:
my_decimal and save_in_field methods implemented for datetime items
sql/my_decimal.cc:
date2my_decimal implemented
sql/my_decimal.h:
date2my_decimal declared
Diffstat (limited to 'sql/field.cc')
-rw-r--r-- | sql/field.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sql/field.cc b/sql/field.cc index 4fea6a085bb..9858e873aa2 100644 --- a/sql/field.cc +++ b/sql/field.cc @@ -2413,6 +2413,13 @@ int Field_new_decimal::store_decimal(const my_decimal *decimal_value) } +int Field_new_decimal::store_time(TIME *ltime, timestamp_type t_type) +{ + my_decimal decimal_value; + return store_value(date2my_decimal(ltime, &decimal_value)); +} + + double Field_new_decimal::val_real(void) { double dbl; |