MYSQL数据库表名以及别名大小写敏感问题
知识点
MYSQL对于表名大小写敏感策略是通过lower_case_table_names参数来设定的,该参数可以在my.ini中配置,如下图所示:
? ? ?
?lower_case_table_names的取值和策略如下:
有大小写敏感问题的原因
u?mysql的表空间文件处理上依赖于操作系统的文件处理策略,mysql在实现创建、修改、读取表空间文件是直接采用操作系统的文件操作接口。
??????从Mysql源码目录mysys下的my_winfile.c的my_create函数,明显看到mysql在windows系统和其他系统创建文件的接口是不一样

[Warning]?You?have?forced?lower_case_table_names?to?0?through?acommand-line?option,?even?though?your?file?system?'C:\MySQL?Server?5.5\Data\'?is?case?insensitive.??This?means?that?you?can?corrupt?a?MyISAM?table?by?accessing?it?with?different?cases.?You?should?consider?changing?lower_case_table_names?to?1?or?2
?
?
参考资料:
Mysql大小写敏感
http://www.cppblog.com/woaidongmao/archive/2009/03/26/77961.html?
了解?NFS?和文件名
http://technet.microsoft.com/zh-cn/library/cc778349(WS.10).aspx?
Mysql源码
http://www.oschina.net/code/explore/mysql-5.5.8/mysys/my_winfile.c?
?
?
?
?
?