1055 - Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column

4人阅读 评论(0) 收藏 举报
分类:

问题:

1055 - Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column ‘cmp-31161029.t1.user_name’ which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by, Time: 0.000000s

查询sql_mode模式设置:

select @@global.sql_mode

结果:

ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION

解决方案:去除 ONLY_FULL_GROUP_BY重新 设置sql_mode

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’

查看评论

#1055 - Expression of SELECT list is not in GROUP BY clause and contains nonaggregated column this i

#1055 - Expression of SELECT list is not in GROUP BY clause and contains nonaggregated column this i
  • demored
  • demored
  • 2017-01-11 11:01:04
  • 6683

Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'userinfo.

安装了mysql5.7,用group by 查询时抛出如下异常:Expression #3 of SELECT list is not in GROUP BY clause and contains ...
  • fansili
  • fansili
  • 2017-11-29 13:27:53
  • 4493

ERROR 1055 (42000): Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregate

ERROR 1055 (42000): Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregate...
  • qq285744011
  • qq285744011
  • 2017-06-12 10:02:41
  • 3980

mysql遇见Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggre的问题

报错如下: Expression #2 of SELECT list is not in GROUP BY clause and contains nonaggregated column ...
  • qq_34707744
  • qq_34707744
  • 2017-09-19 16:20:10
  • 11493

MySQL: Expression #2 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'sss

执行MySQL中sql语句的时候报错,执行的sql语句:SELECT prov_desc, area_desc, month_id, MAX(total_fee)AS ...
  • u010429286
  • u010429286
  • 2017-03-21 16:55:39
  • 8641

[Err] 1055 - Expression #1 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated c

mysql  5.7.13 下出现的问题查询异常 在 /etc/my.cnf 文件里加上如下: sql_mode='NO_ENGINE_SUBSTITUTION' 然后,重启Mysql服...
  • u010320371
  • u010320371
  • 2016-06-19 10:08:46
  • 13690

Expression #1 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated column 'inform

Expression #1 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated column 'inform...
  • u012129607
  • u012129607
  • 2017-03-20 13:18:49
  • 4976

Error Code: 1055. Expression #2 of SELECT list is not in GROUP BY clause and contains nonaggregated

SQL92及更早版本不允许选择列表,HAVING条件或ORDER BY列表引用在GROUP BY子句中未命名的非分组列的查询。例如,在标准SQL92中,此查询是非法的,因为name选择列表中的未列...
  • MissWwg
  • MissWwg
  • 2017-08-30 17:07:34
  • 3080

[Err] 1055 - Expression #1 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated..

[Err] 1055 - Expression #1 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated c...
  • zq33312757
  • zq33312757
  • 2016-11-10 18:08:23
  • 5781

[Err] 1055 - Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated colum

[Err] 1055 - Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated colum
  • li1325169021
  • li1325169021
  • 2017-10-25 17:32:45
  • 999
    个人资料
    持之以恒
    等级:
    访问量: 58万+
    积分: 6443
    排名: 4694
    最新评论