I\'m working on a MySQL database in windows.
I must move it into a Linux environment. MySQL database contains a lot of tables and stored procedures which are CASE
Read all this: http://dev.mysql.com/doc/refman/5.0/en/identifier-case-sensitivity.html
Then add this system variable to the server section, [mysqld]
, of my.ini
and restart mysql:
/my.ini: lower_case_table_names=2
Have a look at this article - http://dev.mysql.com/doc/refman/5.1/en/identifier-case-sensitivity.html
Mode 2 allows to store tables with specified lettercase, but anyway, name comparisons won't be case sensitive and you won't be able to store table1
and Table1
at the same time.
Unfortunately there's no way of making MySQL on windows to behave 100% as in Linux. What you can do, is to run a minimal VM on Virtual Box or VMware player with TurnKey - MySQL Appliance.
In my personal experience, I've found quite useful to have a VM with a configuration similar to the deployment environment to diagnose problems.
On windows put lower_case_table_names=2 at the end of file C:\ProgramData\MySQL\MySQL Server 5.7\my.ini
i add this line and it solve the different case problem
lower_case_table_names=1
in /etc/my.cnf
you can see how to set mysql variable "lower_case_table_names" form this page : https://dev.mysql.com/doc/refman/5.0/en/server-system-variables.html#sysvar_lower_case_table_names
Add this property to lower_case_table_names=2 to my.ini