• Alexander Barkov's avatar
    MDEV-8630 Datetime value dropped in "INSERT ... SELECT ... ON DUPLICATE KEY" · d87bc55b
    Alexander Barkov authored
    Item_func_coalesce::fix_length_and_dec() calls
    Item_func::count_string_result_length()) which called agg_arg_charsets()
    with wrong flags, so the collation derivation of the COALESCE result was
    not properly set to DERIVATION_COERCIBLE. It erroneously stayed
    DERIVATION_NUMERIC. So GREATEST() misinterpreted the argument as
    a number rather that a string and did not calculate its own length properly.
    d87bc55b
item_func.cc 183 KB