Weird error while adding index for MEMORY table with row_format=Dynamic
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Percona Server moved to https://jira.percona.com/projects/PS |
Fix Released
|
Medium
|
Hrvoje Matijakovic | ||
5.1 |
Invalid
|
Undecided
|
Unassigned | ||
5.5 |
Fix Released
|
Medium
|
Hrvoje Matijakovic | ||
5.6 |
Fix Released
|
Medium
|
Hrvoje Matijakovic |
Bug Description
Recent PS 5.5.x versions produce weird error message when index is added for MEMORY table with Dynamic row format. Like this:
mysql> select version();
+-----------------+
| version() |
+-----------------+
| 5.5.31-30.3-log |
+-----------------+
1 row in set (0.02 sec)
mysql> create table tm (c1 int, c2 varchar(2000), c3 date, c4 time) engine=memory row_format=dynamic;
Query OK, 0 rows affected (0.07 sec)
mysql> show table status like 'tm'\G
*******
Name: tm
Engine: MEMORY
Version: 10
Row_format: Dynamic
Rows: 0
Avg_row_length: 256
Data_length: 0
Max_data_length: 16777216
Index_length: 0
Data_free: 0
Auto_increment: NULL
Create_time: 2013-05-28 20:21:40
Update_time: NULL
Check_time: NULL
Collation: latin1_swedish_ci
Checksum: NULL
Create_options: row_format=DYNAMIC
Comment:
1 row in set (0.00 sec)
mysql> create index i1 on tm(c1);
Query OK, 0 rows affected (0.02 sec)
Records: 0 Duplicates: 0 Warnings: 0
mysql> create index i2 on tm(c2);
ERROR 1234 (42000): Incorrect usage/placement of 'key_block_size'
mysql> create index i2 on tm(c3);
ERROR 1234 (42000): Incorrect usage/placement of 'key_block_size'
mysql> create index i2 on tm(c4);
ERROR 1234 (42000): Incorrect usage/placement of 'key_block_size'
mysql> show table status like 'tm'\G
*******
Name: tm
Engine: MEMORY
Version: 10
Row_format: Dynamic
Rows: 0
Avg_row_length: 272
Data_length: 0
Max_data_length: 15845088
Index_length: 0
Data_free: 0
Auto_increment: NULL
Create_time: 2013-05-28 20:21:59
Update_time: NULL
Check_time: NULL
Collation: latin1_swedish_ci
Checksum: NULL
Create_options: row_format=DYNAMIC KEY_BLOCK_SIZE=256
Comment:
1 row in set (0.00 sec)
Related branches
- Alexey Kopytov (community): Approve
-
Diff: 42 lines (+8/-6)3 files modifieddoc/source/flexibility/improved_memory_engine.rst (+2/-0)
doc/source/flexibility/log_warnings_suppress.rst (+5/-5)
doc/source/performance/query_cache_enhance.rst (+1/-1)
- Alexey Kopytov (community): Approve
-
Diff: 70 lines (+8/-27)3 files modifieddoc/source/flexibility/improved_memory_engine.rst (+2/-0)
doc/source/flexibility/log_warnings_suppress.rst (+5/-5)
doc/source/performance/query_cache_enhance.rst (+1/-22)
I see no way to create MEMORY tables with Dynamic row format in PS 5.1.68 or 5.6.10, so I assume the bug does not apply to these versions.