Commit 591cfbff authored by unknown's avatar unknown

item_timefunc.cc:

  5.0 additional fix for b#18691
  Handle DECIMAL the same with INT and REAL.


sql/item_timefunc.cc:
  5.0 additional fix for b#18691
  Handle DECIMAL the same with INT and REAL.
parent 9844f0ab
...@@ -2457,6 +2457,7 @@ void Item_char_typecast::fix_length_and_dec() ...@@ -2457,6 +2457,7 @@ void Item_char_typecast::fix_length_and_dec()
the argument's charset. the argument's charset.
*/ */
from_cs= (args[0]->result_type() == INT_RESULT || from_cs= (args[0]->result_type() == INT_RESULT ||
args[0]->result_type() == DECIMAL_RESULT ||
args[0]->result_type() == REAL_RESULT) ? args[0]->result_type() == REAL_RESULT) ?
(cast_cs->mbminlen == 1 ? cast_cs : &my_charset_latin1) : (cast_cs->mbminlen == 1 ? cast_cs : &my_charset_latin1) :
args[0]->collation.collation; args[0]->collation.collation;
......
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