当前位置:网站首页>which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mod
which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mod
2022-06-11 17:14:00 【年少~年】
编辑
vim /etc/my.cnf
在文件底部加入:
sql_mode=STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
重启:systemctl restart mysqld 结果不成功 ,
查看错误原因
cat /var/log/mysqld.log
/usr/sbin/mysqld: Error while setting value 'STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION' to 'sql_mode'.

原因:8.0以上已经取消了NO_AUTO_CREATE_USER这个关键字,在mysql.ini中的sql_mode中删掉这个关键字即可。
最终配置
sql_mode=STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION

边栏推荐
- Characteristics of interfaces & comparison between interfaces and abstract classes
- “is-a”,“has-a”,“like-a”
- DFS和BFS笔记(一)基于C语言的广度优先搜索
- Elasitcsearch基础学习笔记(1)
- vscode保存代碼時自動eslint格式化
- JPA循环保存多个实体失败
- 10 times faster than 5g. Are you ready for 10 Gigabit communication?
- 字符串转数值
- Analysis report on the "fourteenth five year plan" proposal and innovation environment of global and Chinese sodium pyrophosphate industry (2022-2028)
- Kernel density estimation (2D, 3D)
猜你喜欢

搜狐全員遭詐騙,暴露哪些問題?

vscode保存代碼時自動eslint格式化

Analysis report on competition pattern and future development strategy of China's corn industry 2022-2028 Edition

The use of histogram function in MATLAB

GUI guess number game, directly open play

Science popularization genius on the left, madman on the right

每周推荐短视频:菜鸟CEO谈未来物流新赛道

Create database instance

从制造到“智造”,探索制造企业破局之道

A set of ThinkPHP wechat applet mall source code with background management
随机推荐
论文阅读 dyngraph2vec: Capturing Network Dynamics using Dynamic Graph Representation Learning
^31 prototype interview questions
WYSIWYG markdown editor: typora
Qlineedit set input mask
Katalon Studio Enterprise
啟牛商學院給的證券賬戶是安全的嗎?開戶收費嗎
子类继承了什么、多态、 向上转型
vscode保存代码时自动eslint格式化
SQL injection attack under seed emulator (including SQL environment configuration)
LeetCode——42. Connected to rainwater (double pointer)
Authing 背后的计算哲学
Guide to Dama data management knowledge system: percentage of chapter scores
JPA failed to save multiple entities circularly
AXI协议基础知识
ShellBrowser .NET Crack
Recyclerview cache reuse analysis, source code interpretation
How to store tree structure in database
From a "trendsetter" to a "wind chaser", can master Kang still lead the market?
vscode配置eslint自动格式化报错“Auto Fix is enabled by default. Use the single string form“
Axi protocol Basics