In MySQL, databases and tables correspond to directories and files under those directories. Therefore, the sensitivity of the operating system determines the case sensitivity of the database and table names. This means that the database and table names are case-insensitive in Windows, while in most Unix systems in MySQL, databases and tables correspond to directories and files under those directories. Therefore, the sensitivity of the operating system determines the case sensitivity of the database and table names. This means that the database and table names are case-insensitive in Windows and are case-sensitive in most types of Unix systems. A special case is Mac OS X, which is used by the default HFS + file system. However, Mac OS x also supports UFS volumes, which are case sensitive in Mac OS X, just as they are on any Unix. See section 1.8.3 MySQL extension to ANSI SQL92.
Note: Although the database and table names in Windows are case-insensitive, you should not reference a given database or table in the same query. The following query will not work because it references a table with my_table and MY_TABLE:
Mysql> SELECT * FROM my_table WHERE MY_TABLE.col = 1;
Column names and column aliases are case-insensitive in all cases.
Table aliases are case sensitive. The following query will not work because it uses a and A to reference aliases:
Mysql> SELECT col_name FROM tbl_name AS a WHERE a. col_name = 1 or a. col_name = 2;
If it is difficult to use uppercase or lowercase letters in the memory database and table name, we recommend that you use the same conventions. for example, you can always use lowercase letters to create databases and tables.
Another way to avoid this problem is to start mysqld with The-O lower_case_table_names = 1 parameter. By default, this option is 1 in Windows and 0 in Unix.
If lower_case_table_names is 1, MySQL converts all table names to small lines during storage and search. (This option also applies to database names starting from MySQL 4.0.2 .) Note: When you change this option, you must first convert the old table name to lowercase letters before starting mysqld.
$ Pwd
/Data1/etl/aiinsight/ScheduleServer/mysql/support-files
$./Mysql. server stop
$ Pwd
/Data1/etl/aiinsight/ScheduleServer/mysql/bin
./Mysqld_safe -- lower_case_table_names
Method 2: modify the my. cnf configuration file
In the [mysqld] section, add
Lower_case_table_names = 1