原文:linux下 java.sql.SQLSyntaxErrorException: In aggregated query without GROUP BY, expression this is incompatible with sql_mode=only_full_group_by解決辦法

永久解決辦法,重啟任然生效 .登錄linux服務器 .找到my.cnf 文件 .vim etc my.cnf 分別在 mysqld 和 mysql 下面添加這段 sql mode STRICT TRANS TABLES,NO ZERO IN DATE,NO ZERO DATE,ERROR FOR DIVISION BY ZERO,NO AUTO CREATE USER,NO ENGINE SUBS ...

2020-08-20 16:19 0 491 推薦指數:

查看詳情

; this is incompatible with sql_mode=only_full_group_by

1.這個錯誤發生在mysql 5.7 版本及以上版本會出現的問題: mysql 5.7版本默認的sql配置是:sql_mode="ONLY_FULL_GROUP_BY",這個配置嚴格執行了"SQL92標准" 2.在sql執行時,出現該原因: 簡單來說就是:輸出 ...

Sun May 31 19:34:00 CST 2020 0 6495
 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM