Commit 9fa6589f authored by Sergei Golubchik's avatar Sergei Golubchik

bugfix: TABLE::mark_columns_used_by_index_no_reset

it should not mark base columns that a vcol depends on, because
keyread (on a vcol) will not read them
parent 4dd7e113
......@@ -6146,13 +6146,7 @@ void TABLE::mark_columns_used_by_index_no_reset(uint index, MY_BITMAP *bitmap)
KEY_PART_INFO *key_part_end= (key_part +
key_info[index].user_defined_key_parts);
for (;key_part != key_part_end; key_part++)
{
bitmap_set_bit(bitmap, key_part->fieldnr-1);
if (key_part->field->vcol_info &&
key_part->field->vcol_info->expr)
key_part->field->vcol_info->
expr->walk(&Item::register_field_in_bitmap, 1, bitmap);
}
}
......
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