1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

MDEV-33658 1/2 Refactoring: extract Key length initialization

mysql_prepare_create_table: Extract a Key initialization part that
relates to length calculation and long unique index designation.

append_system_key_parts call also moves there.

Move this initialization before the duplicate elimination.

Extract WITHOUT OVERPLAPS check into a separate function. It had to be moved
earlier in the code to preserve the order of the error checks, as in the tests.
This commit is contained in:
Nikita Malyavin
2024-10-12 21:32:18 +02:00
parent e33064e0fc
commit ecaedbe299
10 changed files with 362 additions and 251 deletions

View File

@@ -659,6 +659,8 @@ NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL 15000
NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL 16000
ALTER TABLE testdb_wl5522.t1 ADD INDEX idx1 (col_1);
ALTER TABLE testdb_wl5522.t1 ADD INDEX idx6 (col_1(255));
Warnings:
Note 1831 Duplicate index `idx6`. This is deprecated and will be disallowed in a future release
ALTER TABLE testdb_wl5522.t1 ADD INDEX idx10 (col_10(255));
SELECT
col_1 = REPEAT("col1_00001",10),