| Bug #19305 | Partitions: COALESCE PARTITION .. does no more remove unused files | ||
|---|---|---|---|
| Submitted: | 24 Apr 2006 18:56 | Modified: | 14 Jun 2006 1:01 |
| Reporter: | Matthias Leich | Email Updates: | |
| Status: | Closed | Impact on me: | |
| Category: | MySQL Server: Partitions | Severity: | S2 (Serious) |
| Version: | 5.1 | OS: | |
| Assigned to: | Mikael Ronström | CPU Architecture: | Any |
[24 Apr 2006 18:57]
Matthias Leich
testcase
Attachment: ml013.test (application/test, text), 369 bytes.
[13 Jun 2006 12:24]
Mikael Ronström
Patch will appear in 5.1.12
[14 Jun 2006 1:01]
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 bugfix in 5.1.12 changelog. Closed.

Description: CREATE TABLE t1 (f_date DATE, f_varchar VARCHAR(30)) PARTITION BY HASH(CAST(YEAR(f_date) AS SIGNED INTEGER)) PARTITIONS 2; SHOW CREATE TABLE t1; Table Create Table t1 CREATE TABLE `t1` ( `f_date` date DEFAULT NULL, `f_varchar` varchar(30) DEFAULT NULL ) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) PARTITIONS 2 /dev/shm/var/master-data/test/t1#P#p0.MYD /dev/shm/var/master-data/test/t1#P#p0.MYI /dev/shm/var/master-data/test/t1#P#p1.MYD /dev/shm/var/master-data/test/t1#P#p1.MYI /dev/shm/var/master-data/test/t1.frm /dev/shm/var/master-data/test/t1.par <-- That means we have two files per partition. ALTER TABLE t1 COALESCE PARTITION 1; SHOW CREATE TABLE t1; Table Create Table t1 CREATE TABLE `t1` ( `f_date` date DEFAULT NULL, `f_varchar` varchar(30) DEFAULT NULL ) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) PARTITIONS 1 /dev/shm/var/master-data/test/t1#P#p0.MYD /dev/shm/var/master-data/test/t1#P#p0.MYI /dev/shm/var/master-data/test/t1#P#p1.MYD /dev/shm/var/master-data/test/t1#P#p1.MYI /dev/shm/var/master-data/test/t1.frm /dev/shm/var/master-data/test/t1.par <-- Till some days ago the files of the coalesced partition disappeared. So the question is: Is this new behaviour really intended ? My environment: - Intel PC with Linux(SuSE 9.3) - MySQL compiled from source Version 5.1 last ChangeSet@1.2353.1.4, 2006-04-23 How to repeat: Please use my attached testscript ml013.test copy it to mysql-test/t echo "Dummy" > r/ml013.result # Produce a dummy file with # expected results ./mysql-test-run ml013