diff options
author | Sergei Golubchik <sergii@pisem.net> | 2014-08-07 18:06:56 +0200 |
---|---|---|
committer | Sergei Golubchik <sergii@pisem.net> | 2014-08-07 18:06:56 +0200 |
commit | 6fb17a06016506498f4de75ff754f500f9f674f1 (patch) | |
tree | d03c86959f150edc0f6f27ca2c06ccbc0e6e5bf0 /sql/item_timefunc.h | |
parent | 2023fac28130d7d3f7d6776332239c62c3890195 (diff) | |
parent | a4ab2431a20f6e2198d980f8e84fa7118515ca3b (diff) | |
download | mariadb-git-6fb17a06016506498f4de75ff754f500f9f674f1.tar.gz |
5.5.39 merge
Diffstat (limited to 'sql/item_timefunc.h')
-rw-r--r-- | sql/item_timefunc.h | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/sql/item_timefunc.h b/sql/item_timefunc.h index 29badddad8e..cb8b59501a4 100644 --- a/sql/item_timefunc.h +++ b/sql/item_timefunc.h @@ -413,16 +413,15 @@ protected: public: Item_func_seconds_hybrid() :Item_func_numhybrid() {} Item_func_seconds_hybrid(Item *a) :Item_func_numhybrid(a) {} - void fix_num_length_and_dec() + void fix_length_and_dec() { if (arg_count) decimals= args[0]->temporal_precision(arg0_expected_type()); set_if_smaller(decimals, TIME_SECOND_PART_DIGITS); max_length=17 + (decimals ? decimals + 1 : 0); maybe_null= true; + cached_result_type= decimals ? DECIMAL_RESULT : INT_RESULT; } - void find_num_type() - { cached_result_type= decimals ? DECIMAL_RESULT : INT_RESULT; } double real_op() { DBUG_ASSERT(0); return 0; } String *str_op(String *str) { DBUG_ASSERT(0); return 0; } bool date_op(MYSQL_TIME *ltime, uint fuzzydate) { DBUG_ASSERT(0); return true; } @@ -470,11 +469,6 @@ protected: public: Item_func_time_to_sec(Item *item) :Item_func_seconds_hybrid(item) {} const char *func_name() const { return "time_to_sec"; } - void fix_num_length_and_dec() - { - maybe_null= true; - Item_func_seconds_hybrid::fix_num_length_and_dec(); - } bool check_partition_func_processor(uchar *int_arg) {return FALSE;} bool check_vcol_func_processor(uchar *int_arg) { return FALSE;} bool check_valid_arguments_processor(uchar *int_arg) |