1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

Merge 10.2 into bb-10.2-ext

This commit is contained in:
Marko Mäkelä
2017-09-20 17:47:49 +03:00
230 changed files with 3599 additions and 2155 deletions

View File

@ -2311,6 +2311,26 @@ int multi_update::do_updates()
do_update= 0; // Don't retry this function
if (!found)
DBUG_RETURN(0);
/*
Update read_set to include all fields that virtual columns may depend on.
Usually they're already in the read_set, but if the previous access
method was keyread, only the virtual column itself will be in read_set,
not its dependencies
*/
while(TABLE *tbl= check_opt_it++)
{
if (tbl->vcol_set)
{
bitmap_clear_all(tbl->vcol_set);
for (Field **vf= tbl->vfield; *vf; vf++)
{
if (bitmap_is_set(tbl->read_set, (*vf)->field_index))
tbl->mark_virtual_col(*vf);
}
}
}
for (cur_table= update_tables; cur_table; cur_table= cur_table->next_local)
{
bool can_compare_record;