当前位置:网站首页>Different lower_case_table_names settings for server (‘1‘) and data dictionary (‘0‘) 解决方案
Different lower_case_table_names settings for server (‘1‘) and data dictionary (‘0‘) 解决方案
2022-07-31 11:27:00 【m0_67392409】
问题情景
在使用洛伊框架的时候,数据库表找不到的问题。下结论是mysql区分大小写导致的问题。
lower_case_table_names 参数
官方原话,简单来说就是,unix默认是0,windows默认是1,mac是2。
0是区分大小写的,1是不区分的,也就是windows是默认不区分大小写的。
On Unix, the default value of lower_case_table_names is 0. On Windows, the default value is 1. On macOS, the default value is 2.
问题解决
我翻阅了大量资料,都是说在配置文件配置lower_case_table_names=1,重启服务可以解决问题。
后来经过我查阅mysql官方文档资料发现:该解决方案只能在5.6/5.7低版本的mysql中有效。
但是在8.0版本下是行不通的,就算怎么做lower_case_table_names变量也没有得到更新。
官方mysql8.0版本新增的一条说明
lower_case_table_names can only be configured when initializing the server. Changing the lower_case_table_names setting after the server is initialized is prohibited.
翻译:
LOWER_CASE_TABLE_NAMES只能在初始化服务器时配置。禁止在服务器初始化后更改LOWER_CASE_TABLE_NAMES设置。
也就是说在8.0版本,你的mysql已经初始化过就不支持修改lower_case_table_names参数了!!
如果你的是8版本这边建议你直接重装。
在my.cnf(可能名字不同)文件中添加lower_case_table_names=1
在初始化的时候需要指定lower_case_table_names=1参数
这是我找到最靠谱的重装教程:https://blog.csdn.net/qq_37598011/article/details/93489404
先自我介绍一下,小编13年上师交大毕业,曾经在小公司待过,去过华为OPPO等大厂,18年进入阿里,直到现在。深知大多数初中级java工程师,想要升技能,往往是需要自己摸索成长或是报班学习,但对于培训机构动则近万元的学费,着实压力不小。自己不成体系的自学效率很低又漫长,而且容易碰到天花板技术停止不前。因此我收集了一份《java开发全套学习资料》送给大家,初衷也很简单,就是希望帮助到想自学又不知道该从何学起的朋友,同时减轻大家的负担。添加下方名片,即可获取全套学习资料哦
边栏推荐
- MySQL模糊查询性能优化
- Distributed Transactions - Introduction to Distributed Transactions, Distributed Transaction Framework Seata (AT Mode, Tcc Mode, Tcc Vs AT), Distributed Transactions - MQ
- 【Web技术】1397- 深入浅出富文本编辑器
- MySql模糊查询大全
- 拥抱趋势!阿里这套微服务开源框架权威手册,实战到底层细致清晰
- 分布式事务Seata详细使用教程
- AtCoder—E - Σ[k=0..10^100]floor(X/10^k
- mpu9150(driverack pa简明教程)
- The most complete phpmyadmin vulnerability summary
- MySQL index usage and optimization
猜你喜欢

In PLC communication error or timeout or download the prompt solution of the model

“带薪划水”偷刷阿里老哥的面经宝典,三次挑战字节,终成正果

deeplab实现自己遥感地质分割数据集

多线程学习笔记-2.final关键字和不变性

Read through the interface to call the artifact RestTemplate

Redis-基础

Docker搭建Mysql主从复制

ApiPost is really fragrant and powerful, it's time to throw away Postman and Swagger

淀粉与纤维素

Cloudera Manager —— 端到端的企业数据中心管理工具
随机推荐
LeetCode - 025. 链表中的两数相加
使用内存映射加快PyTorch数据集的读取
mysql 索引使用与优化
Distributed Transactions - Introduction to Distributed Transactions, Distributed Transaction Framework Seata (AT Mode, Tcc Mode, Tcc Vs AT), Distributed Transactions - MQ
新人学习小熊派华为iot介绍
7 天学个Go,Go 结构体 + Go range 来学学
Curl 命令使用
Hospital management system database, course design, SQLserver, pure code design
3D激光SLAM:LeGO-LOAM论文解读---点云分割部分
Redis学习笔记-3.慢查询和其他高级数据结构
xmind使用指南(XMind具有下列哪些功能)
WSL2安装.NET 6
Distributed id solution
淀粉与纤维素
Redis缓存面临的缓存穿透问题
1161. 最大层内元素和 (二叉树的层序遍历)
mpu9150(driverack pa简明教程)
科学论文和学术论文写作
Master SSR
502 bad gateway原因、解决方法