[MDEV-28822] Table from older version requires table rebuild when adding column to table with multi-column index Created: 2022-06-13 Updated: 2023-01-26 Resolved: 2022-10-26 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Data Definition - Alter Table |
| Affects Version/s: | 10.5.16 |
| Fix Version/s: | 10.5.18, 10.6.11, 10.7.7, 10.8.6, 10.9.4, 10.10.2 |
| Type: | Bug | Priority: | Critical |
| Reporter: | Hartmut Holzgraefe | Assignee: | Alexander Barkov |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | regression-10.5 | ||
| Attachments: |
|
||||||||||||||||||||||||||||||||||||||||||||
| Issue Links: |
|
||||||||||||||||||||||||||||||||||||||||||||
| Description |
|
How to reproduce: On a 10.4 server instance do:
Then upgrade to 10.5 and try to instant-add a column:
This fails with:
Same table created on 10.5 right away allows to add the column in instant mode just fine. |
| Comments |
| Comment by Marko Mäkelä [ 2022-06-14 ] |
|
hholzgra, thank you for the report. This resembles To speed up analysis, could you please attach a minimal 10.4 data directory with which the ALTER TABLE statement would fail? Did you try specifying different collations for the column msg? From the InnoDB point of view it should make no difference, but for some presumably incorrect check in the SQL layer it might. It is the SQL layer that produces the operation flags for InnoDB. If an operation flag is set that is not supported in an instant operation by InnoDB, then an error will be reported, even if that flag were set unnecessarily. |
| Comment by Marko Mäkelä [ 2022-06-14 ] |
|
A private comment mentioned HA_PACK_KEY, which I see was added |
| Comment by Hartmut Holzgraefe [ 2022-06-14 ] |
|
> Did you try specifying different collations for the column msg? I didn't try using different collations, but I did try both with default charset, and with explicit latin1 or utf8 in the CREATE statement. > To speed up analysis, could you please attach a minimal 10.4 data directory with which the ALTER TABLE statement would fail? attaching in a minute |