Bug #16684 Error in calculation of partition id for RANGE partitioned tables
Submitted: 20 Jan 2006 19:48 Modified: 2 Mar 2006 6:29
Reporter: Mikael Ronström Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Partitions Severity:S1 (Critical)
Version:5.1.5 OS:Linux (RHEL)
Assigned to: Mikael Ronström CPU Architecture:Any

[20 Jan 2006 19:48] Mikael Ronström
Description:
CREATE TABLE t (a int)
PARTITION BY RANGE (a)
(PARTITION p10 values less than (10),
 PARTITION p30 values less than (30),
 PARTITION p50 values less than (50),
 PARTITION p70 values less than (70),
 PARTITION p90 values less than (90));

Now insert into t (30); should go into p50 but it rather goes into p30

How to repeat:
See desctiption

Suggested fix:
< changed to <= in while-loop in
get_partition_id_range and get_partition_id_range_endpoint
[1 Mar 2006 13:21] Mikael Ronström
Was fixed in release 5.1.6
[2 Mar 2006 6:29] Jon Stephens
Thank you for your bug report. This issue has already been fixed
in the latest released version of that product, which you can download at 
http://www.mysql.com/downloads/

Additional info:

Documented fix in 5.1.6 changelog. Closed.