[Linux 完美解决]Expression #5 of SELECT list is not in GROUP BY clause and contains nonaggregated column
错误
Expression #5 of SELECT list is not in GROUP BY clause and contains nonaggregated column
一、找到关于mysql的my.cnf文件
不清楚的可以使用 find / -name my.cnf查看文件路径
[root@localhost /]# find / -name my.cnf
/etc/my.cnf
二、在my.cnf的[mysqld] 下面添加一行数据
sql_mode=STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION