Up to 16 columns.
Create Table Test (
F1 int,
F2 int,
F3 int,
F4 int,
F5 int,
F6 int,
F7 int,
F8 int,
F9 int,
F10 int,
F11 int,
F12 int,
F13 int,
F14 int,
F15 int,
F16 int,
F17 int
);
Create index idx_test_16 on test (F1, F2, F3, F4, F5, F6, F7, F8, F9, F10, F11, F12, f13, F14, F15, F16 );
Create index idx_test_17 on test (F1, F2, F3, F4, F5, F6, F7, F8, F9, F10, F11, F12, f13, F14, F15, F16, f17 );
The running result is as follows:
Mysql> Create Table Test (
-> F1 int,
-> F2 int,
-> F3 int,
-> F4 int,
-> F5 int,
-> F6 int,
-> F7 int,
-> F8 int,
-> F9 int,
-> F10 int,
-> F11 int,
-> F12 int,
-> F13 int,
-> F14 int,
-> F15 int,
-> F16 int,
-> F17 int
-> );
Query OK, 0 rows affected (0.06 Sec)
Mysql>
Mysql> Create index idx_test_16 on test (F1, F2, F3, F4, F5, F6, F7, F8, F9, F10, F11, F12, f13, F14, F15, f16 );
Query OK, 0 rows affected (0.02 Sec)
Records: 0 duplicates: 0 Warnings: 0
Mysql> Create index idx_test_17 on test (F1, F2, F3, F4, F5, F6, F7, F8, F9, F10, F11, F12, f13, F14, F15, F16, f17 );
Error 1070 (42000): Too primary key parts specified; Max 16 parts allowed
Mysql>