Bug #13437 Partitions: table files can be same as partition files
Submitted: 23 Sep 2005 17:35 Modified: 20 Jan 2006 8:23
Reporter: Peter Gulutzan Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Partitions Severity:S3 (Non-critical)
Version:5.1.2-alpha-debug OS:Linux (SUSE 9.2)
Assigned to: Mikael Ronström CPU Architecture:Any

[23 Sep 2005 17:35] Peter Gulutzan
Description:
I can create a table named tm_p0 which uses tm_p0.MYD and tm_p0.MYI.
I can create a partition named tm with a partition p0 -- which
uses tm_p0.MYD and tm_p0.MYI. So when I insert into tm_p0, the
row also goes into tm. 

How to repeat:
mysql> CREATE TABLE tm_p0 (s1 INT);
Query OK, 0 rows affected (0.01 sec)

mysql> CREATE TABLE tm (s1 INT) PARTITION BY KEY (s1);
Query OK, 0 rows affected (0.00 sec)

mysql> INSERT INTO tm VALUES (0);
Query OK, 1 row affected (0.00 sec)

mysql> SELECT * FROM tm_p0;
+------+
| s1   |
+------+
|    0 |
+------+
1 row in set (0.00 sec)
[19 Oct 2005 11:03] Jon Stephens
Changed category to Server/Partitioning.
[9 Jan 2006 7:28] Mikael Ronström
Changed from _ between table and partition name to #P# and to
#SP# between partition and subpartition name
Given that # is not allowed in table names this should now make it safe
[19 Jan 2006 9:16] Mikael Ronström
Patch pushed and will appear in 5.1.6
[20 Jan 2006 8:23] Jon Stephens
Thank you for your bug report. This issue has been committed to our
source repository of that product and will be incorporated into the
next release.

If necessary, you can access the source repository and build the latest
available version, including the bugfix, yourself. More information 
about accessing the source trees is available at
    http://www.mysql.com/doc/en/Installing_source_tree.html

Additional info:

Documented as incompatible feature change in 5.1.6 changelog. Closed.