当前位置:网站首页>MySQL 5.7.9版本sql_mode=only_full_group_by问题
MySQL 5.7.9版本sql_mode=only_full_group_by问题
2022-07-21 11:07:00 【全栈程序员站长】
大家好,又见面了,我是你们的朋友全栈君。
用到GROUP BY 语句查询时com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Expression #2 of SELECT list is not in GROUP BY clause and contains nonaggregated column ‘col_user_6.a.START_TIME’ which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by错误
解决方法 (修改全局):执行set global sql_mode = ”; 把sql_mode 改成非only_full_group_by模式。验证是否生效 SELECT @@GLOBAL.sql_mode 或 SELECT @@sql_mode
执行(只是修改会话级别的,只是当前会话生效)set session sql_mode = ”; 把sql_mode 改成非only_full_group_by模式。验证是否生效 SELECT @@GLOBAL.sql_mode 或 SELECT @@sql_mode
发布者:全栈程序员栈长,转载请注明出处:https://javaforall.cn/124518.html原文链接:https://javaforall.cn
边栏推荐
- Part 107 interestratemodel in compound
- 第106篇 Compound 中的 Governance
- Talking about the application of service worker in caching resources and web push
- Unity代码通过Package Manager导入包的方法
- 浅谈npm 构建流程及package.json和 package.lock.json的工作流程
- Chapter 97 notes - abstraction in solidity
- How to make the demand unable to go online smoothly as scheduled (V) business acceptance stage
- 记一次去除连接数限制问题
- 訓練精度媲美 AlphaFold2、速度翻倍,飛槳螺旋槳HelixFold訓練和推理代碼全面開源...
- “F5G+EIoT“构建能源物联网,助力电力物联网数据服务
猜你喜欢
SAP ABAP parsing function text of Excel file_ CONVERT_ XLS_ TO_ SAP single step analysis
ASP. Net GridView dynamically displays hidden columns and saves the customer's configuration (user control cookie version)
ANSVC无功补偿装置助力江苏某环保能源项目
Run busybox, buildroot, loognix, qt5.12 system for Godson development board process
CLion配置WSL工具链
浏览器缓存机制解析
从0开始实现一个代理池
Design and application of prepaid platform on power reform policy
一招教你拿捏网上视频
浅谈npm 构建流程及package.json和 package.lock.json的工作流程
随机推荐
第95篇 笔记-solidity中的继承(Inheritance)
Dialogue ace phase IV: challenges and opportunities for the future development of distributed databases
IDEA 2020.1 取消参数名称显示
SAP ABAP parsing function text of Excel file_ CONVERT_ XLS_ TO_ SAP single step analysis
PostgreSQL每周新闻—2022年7月13日
Comptroller in compound, part 105
(板子)试除法求约数
Advanced Fruits(公共子序列)
第104篇 Compound 中的 cTokens
npm 与 yarn 发展史
How to make the demand unable to go online smoothly as scheduled (V) business acceptance stage
Seaborn draws box chart and line chart
taokeeper 环境搭建
高度关注!2022 开放原子开源峰会最新议程一览
Application of DC distribution system products at the end of data center
[机缘参悟-48]:鬼谷子-第七揣篇-提前收集信息、提前做出预判和实施计划
数据库索引:索引并不是万能药
訓練精度媲美 AlphaFold2、速度翻倍,飛槳螺旋槳HelixFold訓練和推理代碼全面開源...
Unity代码通过Package Manager导入包的方法
“F5G+EIoT“构建能源物联网,助力电力物联网数据服务