报错内容
Expression
#1
of
SELECT
list is
not
in
GROUP
BY
clause and
contains nonaggregated column 'game.name'
which is
not
functionally dependent on
columns in
GROUP
BY
clause; this is
incompatible with
sql_mode=only_full_group_by
解决方法
在/etc/my.cnf里面添加
sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
本文介绍了解决MySQL中因sql_mode设置为only_full_group_by导致的查询错误的方法。通过调整my.cnf文件中的sql_mode配置,可以解决非聚合列不在GROUP BY子句中的问题。
4825

被折叠的 条评论
为什么被折叠?



