MySQL表名 区分大小写

官方文档说的很清楚 嘿嘿 

lower_case_table_names

Command-Line Format	--lower_case_table_names[=#]
System Variable	Name	lower_case_table_names
Variable Scope	Global
Dynamic Variable	No
Permitted Values	Type	integer
Default	0
Min Value	0
Max Value	2

If set to 0, table names are stored as specified and comparisons are case sensitive. If set to 1, table names are stored in lowercase on disk and 
comparisons are not case sensitive. If set to 2, table names are stored as given but compared in lowercase. This option also applies to database 
names and table aliases. For additional information, see Section 9.2.2, “Identifier Case Sensitivity”.

You should not set this variable to 0 if you are running MySQL on a system that has case-insensitive file names (such as Windows or OS X). If you 
set this variable to 0 on such a system and access MyISAM tablenames using different lettercases, index corruption may result. On Windows the 
default value is 1. On OS X, the default value is 2.

If you are using InnoDB tables, you should set this variable to 1 on all platforms to force names to be converted to lowercase.

The setting of this variable has no effect on replication filtering options. This is a known issue which is fixed in MySQL 5.6. See Section 17.2.3, 
“How Servers Evaluate Replication Filtering Rules”, for more information.

You should not use different settings for lower_case_table_names on replication masters and slaves. In particular, you should not do this when the 
slave uses a case-sensitive file system, as this can cause replication to fail. This is a known issue which is fixed in MySQL 5.6. For more information, 
see Section 17.4.1.36, “Replication and Variables”. 




  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值