错误代码: 1054 Unknown column 't.createUsrId' in 'group statement'

1、错误描写叙述

1 queries executed, 0 success, 1 errors, 0 warnings

查询:select count(t.id),t.`createUserId` from t_acs_ints t where t.id not in (SELECT t1.ionId FROM t_acs_cont t1, t_ac...

错误代码: 1054
Unknown column 't.createUsrId' in 'group statement'

运行耗时   : 0 sec
传送时间   : 0 sec
总耗时      : 0 sec

2、错误原因

     在SQL语句分组时。因为粗心导致字段少写一个字母,导致该字段无法识别(即在表中不存在),致使报错;数据库表的字段名为createUserId,而在group by后面写成了createUsrId


3、解决的方法

     将group by后字段名改动成group by t.createUserId

posted @ 2017-04-17 21:51  zsychanpin  阅读(2572)  评论(0编辑  收藏  举报