| Bug #81712 | lower_case_table_names=2 ignored on ADD PARTITION on Windows | ||
|---|---|---|---|
| Submitted: | 3 Jun 2016 13:32 | Modified: | 6 Jun 2016 8:07 |
| Reporter: | Lukas Potensky | Email Updates: | |
| Status: | Verified | Impact on me: | |
| Category: | MySQL Server: Partitions | Severity: | S2 (Serious) |
| Version: | 5.7.12, 5.6.31, 5.7.13 | OS: | Windows (Microsoft Windows 7 Professional 64bit Service Pack 1) |
| Assigned to: | CPU Architecture: | Any | |
| Tags: | ADD PARTITION, lower_case_table_names | ||
[6 Jun 2016 8:07]
MySQL Verification Team
Hello Lukas Potensky, Thank you for the report and test case. Observed this with 5.6.31/5.7.13 builds on Win7. Thanks, Umesh

Description: Windows 7 SP1 64bit, MySQL 5.7.12, InnoDB database, lower_case_table_names=2 Adding partition using ALTER TABLE ... ADD PARTITION statement to table with mixed case i.e. `CammelCaseTable` renames the table to lowercase i.e. `cammelcasetable`. The table definition .frm file is renamed to lowercase on the filesystem as well. The lower_case_table_names=2 setting is ignored. How to repeat: CREATE TABLE `CammelCaseTable` ( `Id` int(11) NOT NULL AUTO_INCREMENT, `TStamp` datetime NOT NULL, PRIMARY KEY (`Id`,`TStamp`) ) PARTITION BY RANGE COLUMNS(`TStamp`) (PARTITION `p20160601` VALUES LESS THAN ('2016-06-01')); ALTER TABLE `CammelCaseTable` ADD PARTITION (PARTITION `p20160602` VALUES LESS THAN ('2016-06-02')); Now `CammelCaseTable`is renamed to `cammelcasetable`. Suggested fix: Respect the lower_case_table_names=2 setting on ALTER TABLE ... ADD PARTITION.