diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2020-06-13 19:01:28 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2020-06-13 19:01:28 +0300 |
commit | 805340936aa47493886bafd119863d83c475f45c (patch) | |
tree | 46e5a4bd2e8311ef2880caa0526ce705a40c925e /sql/item_func.h | |
parent | f9e53a659c87f1147d4f6d004702077d4d0ce5d7 (diff) | |
parent | d83a4432503d199f6aed8e378563b08471d090dc (diff) | |
download | mariadb-git-805340936aa47493886bafd119863d83c475f45c.tar.gz |
Merge 10.3 into 10.4
Diffstat (limited to 'sql/item_func.h')
-rw-r--r-- | sql/item_func.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/item_func.h b/sql/item_func.h index 996a445617b..a8727272adc 100644 --- a/sql/item_func.h +++ b/sql/item_func.h @@ -970,11 +970,11 @@ class Item_num_op :public Item_func_numhybrid decimals= 0; set_handler(type_handler_long_or_longlong()); } - void fix_length_and_dec_temporal() + void fix_length_and_dec_temporal(bool downcast_decimal_to_int) { set_handler(&type_handler_newdecimal); fix_length_and_dec_decimal(); - if (decimals == 0) + if (decimals == 0 && downcast_decimal_to_int) set_handler(type_handler_long_or_longlong()); } bool need_parentheses_in_default() { return true; } |