2020 一月 24 , 星期五
Home / 数据存储 / mysql / mysql5.7: Expression #2 of SELECT list is not in GROUP BY clause and contains nonaggre

mysql5.7: Expression #2 of SELECT list is not in GROUP BY clause and contains nonaggre

去掉only_full_group_by
set global sql_mode=’STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION’;
set session sql_mode=’STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION’;

Check Also

mysql Incorrect datetime value

从本地 迁移数据库到测试服 发 ...

发表评论

电子邮件地址不会被公开。 必填项已用 * 标注

您可以使用这些 HTML 标签和属性: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>