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

MDEV-23295 ROW_FORMAT mismatch in instant ALTER TABLE

An instant ADD/DROP/reorder column could create a dummy table
object with the wrong ROW_FORMAT when innodb_default_row_format
was changed between CREATE TABLE and ALTER TABLE.

prepare_inplace_alter_table_dict(): If we had promised that
ALGORITHM=INPLACE is supported, we must preserve the ROW_FORMAT.

dict_table_t::prepare_instant(): Add debug assertions to catch
ROW_FORMAT mismatch.

The rest of the changes are related to adding
Alter_inplace_info::inplace_supported to cache the return value of
handler::check_if_supported_inplace_alter().
This commit is contained in:
Marko Mäkelä
2020-07-27 15:04:04 +03:00
parent 4968fdbcef
commit fd9ca2a742
9 changed files with 73 additions and 19 deletions

View File

@ -2440,6 +2440,9 @@ public:
/** true for online operation (LOCK=NONE) */
bool online;
/** which ALGORITHM and LOCK are supported by the storage engine */
enum_alter_inplace_result inplace_supported;
/**
Can be set by handler to describe why a given operation cannot be done
in-place (HA_ALTER_INPLACE_NOT_SUPPORTED) or why it cannot be done