Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
10.4(EOL), 10.5, 10.6, 10.7(EOL), 10.8(EOL), 10.9(EOL), 10.10(EOL), 10.11, 11.0(EOL), 11.1(EOL)
Description
The instant ALTER TABLE changes related to MDEV-11424 are using an unnecessarily complex set of API calls. MDEV-29495 improved this by introducing the virtual member function handler::can_convert_nocopy(). This should be cleaned up further by moving the logic from the MDEV-14016 function instant_alter_column_possible() to ha_innobase::can_convert_nocopy(). bar thinks that this is a prerequisite for implementing MDEV-30934.
The high level idea is that handler::can_convert_nocopy() checks if a table rebuild can be avoided for altering a column definition, by checking if:
- the data type of the new column is semantically a super type for the old column, and
- the low level encoding for all data of the old column is compatible with the encoding of the new column.
Attachments
Issue Links
- blocks
-
MDEV-30934 InnoDB: Changing a Column Data Type from VARCHAR/TEXT to a super type causes a unexpected Table Rebuild
- Open
- is blocked by
-
MDEV-29495 Generalize can_convert_xxx() hook engine API to cover any arbitrary data type
- Closed
- relates to
-
MDEV-14016 Allow instant ADD COLUMN, ADD INDEX, LOCK=NONE
- Closed