-
Guilhem Bichot authored
It was a communication mismatch between sql layer and innodb. The following Alter_inplace_info flags are split into a flag for virtual columns and a flag for stored columns: ALTER_ADD_COLUMN, ALTER_DROP_COLUMN, ALTER_COLUMN_TYPE, ALTER_COLUMN_ORDER. With this finer-grained information, InnoDB's logic is improved: - more operations are in-place - operations which should not be in-place are better caught. Some flags from Alter_info are not needed anymore and removed: ALTER_STORED_GCOLUMN, ALTER_VIRTUAL_GCOLUMN ; the former was part of Alter_info which is intended for parser<->DDL communication; that flag was used for communication between different functions of the server in a DDL, which isn't the mission of Alter_info but of Alter_table_ctx; it is replaced with a new Alter_table_ctx::requires_generated_column_server_evaluation. HA_ALTER_STORED_GCOL was also unneeded and removed. ALTER_STORED_COLUMN_ORDER is set by a logic which ignores virtual columns; indeed the creation/removal of those is not affecting the format of rows. This allows in-place ALTER when adding/removing a virtual column.
Guilhem Bichot authoredIt was a communication mismatch between sql layer and innodb. The following Alter_inplace_info flags are split into a flag for virtual columns and a flag for stored columns: ALTER_ADD_COLUMN, ALTER_DROP_COLUMN, ALTER_COLUMN_TYPE, ALTER_COLUMN_ORDER. With this finer-grained information, InnoDB's logic is improved: - more operations are in-place - operations which should not be in-place are better caught. Some flags from Alter_info are not needed anymore and removed: ALTER_STORED_GCOLUMN, ALTER_VIRTUAL_GCOLUMN ; the former was part of Alter_info which is intended for parser<->DDL communication; that flag was used for communication between different functions of the server in a DDL, which isn't the mission of Alter_info but of Alter_table_ctx; it is replaced with a new Alter_table_ctx::requires_generated_column_server_evaluation. HA_ALTER_STORED_GCOL was also unneeded and removed. ALTER_STORED_COLUMN_ORDER is set by a logic which ignores virtual columns; indeed the creation/removal of those is not affecting the format of rows. This allows in-place ALTER when adding/removing a virtual column.
Loading