当前位置:网站首页>MySQL reports an error "expression 1 of select list is not in group by claim and contains nonaggre" solution
MySQL reports an error "expression 1 of select list is not in group by claim and contains nonaggre" solution
2022-07-03 10:36:00 【Twilight drainage software】
solve MySQL5.7 Use after version GROUP BY Wrong sentence
Use today mysql A simple grouping query statement (GROUP BY) Wrong report .
mysql> SELECT * FROM tb GROUP BY empid;
ERROR 1055 (42000): Expression #2 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'db1.tb.sales' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by

Checked the cause of the problem and the solution , Successfully solved .
Question why
reason : Use GROUP BY Statement violated sql_mode=only_full_group_by. because mysql edition 5.7 Then the default mode is ONLY_FULL_GROUP_BY. Original words of official website documents :
边栏推荐
- Anaconda installation package reported an error packagesnotfounderror: the following packages are not available from current channels:
- Hands on deep learning pytorch version exercise solution - 2.4 calculus
- Multi-Task Feature Learning for Knowledge Graph Enhanced Recommendation
- Judging the connectivity of undirected graphs by the method of similar Union and set search
- Knowledge map reasoning -- hybrid neural network and distributed representation reasoning
- Handwritten digit recognition: CNN alexnet
- Leetcode skimming ---283
- Model evaluation and selection
- A complete answer sheet recognition system
- 深度学习入门之线性代数(PyTorch)
猜你喜欢

Drop out (pytoch)

ThreadLocal原理及使用场景

A complete mall system

Hands on deep learning pytorch version exercise solution -- implementation of 3-2 linear regression from scratch

Free online markdown to write a good resume

Data preprocessing - Data Mining 1

Jetson TX2 brush machine

Leetcode - 5 longest palindrome substring

Weight decay (pytorch)

神经网络入门之预备知识(PyTorch)
随机推荐
20220607 others: sum of two integers
Class-Variant Margin Normalized Softmax Loss for Deep Face Recognition
Ut2016 learning notes
20220608 other: evaluation of inverse Polish expression
Timo background management system
Content type ‘application/x-www-form-urlencoded;charset=UTF-8‘ not supported
Leetcode - the k-th element in 703 data flow (design priority queue)
20220609 other: most elements
实战篇:Oracle 数据库标准版(SE)转换为企业版(EE)
Install yolov3 (Anaconda)
Leetcode刷题---977
熵值法求权重
A complete answer sheet recognition system
Leetcode刷题---704
Ind FHL first week
20220604 Mathematics: square root of X
LeetCode - 715. Range module (TreeSet)*****
MySQL报错“Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggre”解决方法
Content type ‘application/x-www-form-urlencoded; charset=UTF-8‘ not supported
ThreadLocal原理及使用场景