Bug #51470 | subpartition by key need an expression | ||
---|---|---|---|
Submitted: | 24 Feb 2010 17:36 | Modified: | 30 Mar 2010 13:37 |
Reporter: | Cyril SCETBON | Email Updates: | |
Status: | Verified | Impact on me: | |
Category: | MySQL Server: Partitions | Severity: | S2 (Serious) |
Version: | 5.1, 5.5.1, 5.6.99 | OS: | Any |
Assigned to: | CPU Architecture: | Any | |
Tags: | key, partitioning |
[24 Feb 2010 17:36]
Cyril SCETBON
[22 Mar 2010 15:35]
Cyril SCETBON
any idea ?
[22 Mar 2010 19:18]
Sveta Smirnova
Thank you for the report. Verified as described: page http://dev.mysql.com/doc/refman/5.1/en/partitioning-subpartitions.html contains information about SUBPARTITION BY KEY exists, but has no example of its usage. See bug #45904 for correct syntax.
[30 Mar 2010 13:23]
Jon Stephens
This is s Server bug. The statement is valid, and if you specify the primary key, it works, although this should not be required, since per http://dev.mysql.com/doc/refman/5.1/en/partitioning-key.html, "Beginning with MySQL 5.1.6, KEY takes a list of zero or more column names. Where no column name is specified as the partitioning key, the table's primary key is used, if there is one." Since the table has an explicit primary key, it should be used by KEY(). I know of no reason why SUBPARTITION BY KEY should be any different than PARTITION BY KEY in this regard.
[31 Mar 2010 9:50]
Jon Stephens
As requested, I've added a note about this issue to the Subpartitioning section, and additional discussion + example in 'Partitioning Limitations' - http://lists.mysql.com/commits/104683