Bug #68208 alter table changes table name casing to all lowercase
Submitted: 28 Jan 2013 18:25 Modified: 28 Jan 2013 22:52
Reporter: Vince Eagen Email Updates:
Status: Not a Bug Impact on me:
None 
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:5.2.44 CE rev 9933 OS:Windows (win7)
Assigned to: CPU Architecture:Any
Tags: casing

[28 Jan 2013 18:25] Vince Eagen
Description:
When I create a table, e.g. "myTable" the casing is initially preserved on the left hand Object Browser.  A subsequent "Alter Table" will reset the "Table Name" to all lowercase.

How to repeat:
create table "myTable"
close the editor
Alter myTable
observe changed table name case in the "Table Name" field (all lowercase)

Suggested fix:
preserve the casing
[28 Jan 2013 18:37] Vince Eagen
initial table def

Attachment: bug68208-screen1.png (image/png, text), 25.68 KiB.

[28 Jan 2013 18:38] Vince Eagen
case changes on subsequent alter table

Attachment: bug68208-screen2.png (image/png, text), 29.26 KiB.

[28 Jan 2013 18:39] Vince Eagen
changed synopsis
[28 Jan 2013 21:59] MySQL Verification Team
The MySQL Server is a Windows server?. If yes please provide the result of the below command:

mysql> show variables like "%case%";
+------------------------+-------+
| Variable_name          | Value |
+------------------------+-------+
| lower_case_file_system | ON    |
| lower_case_table_names | 1     |
+------------------------+-------+
2 rows in set (0.03 sec)

Thanks.
[28 Jan 2013 22:28] Vince Eagen
Thanks for the reply.  You caught me, it's Windows with the default 'lower_case_table_names' setting.  I changed the value to 2 and it works better now.

mysql> show variables like "%case%";
+------------------------+-------+
| Variable_name          | Value |
+------------------------+-------+
| lower_case_file_system | ON    |
| lower_case_table_names | 2     |
+------------------------+-------+
2 rows in set (0.00 sec)

I checked the SQL that the workbench sends and it has the correct casing.  Should we close this bug and open one for the unupdated casing on the Object Browser or should we repurpose this one?
[28 Jan 2013 22:49] MySQL Verification Team
Thank you for the feedback. Since it isn't related to alter table then open a new bug report. Thanks.
[28 Jan 2013 22:52] Vince Eagen
Will do, thanks for the quick replies.