mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
MDEV-29924 Assertion `(((nr) % (1LL << 24)) % (int) log_10_int[6 - dec]) == 0' failed in my_time_packed_to_binary on SELECT when using TIME field
when assigning the cached item to the Item_cache for the first time make sure to use Item_cache::setup(), not Item_cache::store(). Because the former copies the metadata (and allocates memory, in case of Item_cache_row), and Item_cache::decimal must be set for comparisons to work correctly.
This commit is contained in:
@ -3753,8 +3753,10 @@ int select_max_min_finder_subselect::send_data(List<Item> &items)
|
||||
{
|
||||
cache= val_item->get_cache(thd);
|
||||
set_op(val_item->type_handler());
|
||||
cache->setup(thd, val_item);
|
||||
}
|
||||
cache->store(val_item);
|
||||
else
|
||||
cache->store(val_item);
|
||||
it->store(0, cache);
|
||||
}
|
||||
it->assigned(1);
|
||||
|
Reference in New Issue
Block a user