首页 > 其他分享 >SELECT list is not in GROUP BY clause and contains nonaggregated column 'uav.case_board.port�

SELECT list is not in GROUP BY clause and contains nonaggregated column 'uav.case_board.port�

时间:2024-04-09 13:23:35浏览次数:17  
标签:case GROUP NO clause ZERO sql SELECT

 

mysql 5.7以上版本抛出错误,SELECT list is not in GROUP BY clause and contains nonaggregated column 'uav.case_board.port' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by

groug by在5.7以上的版本在ONLY_FULL_GROUP_BY这个模式下,需要每个字段值非空,配置一下mysql

set @@GLOBAL.sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION';
set @@SESSION.sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION';

SELECT @@GLOBAL.sql_mode;
SELECT @@SESSION.sql_mode;

标签:case,GROUP,NO,clause,ZERO,sql,SELECT
From: https://www.cnblogs.com/youran-he/p/18123744

相关文章

  • CEF编译报错:ValueError: path is on mount '\\\\tab_group_types.mojom-webui.js'
    F:\code\chromium_git\chromium\src>autoninja-Cout\Debug_GN_x64cef"f:\code\depot_tools\bootstrap-2@3_11_6_chromium_30_bin\python3\bin\python3.exe"F:\code\depot_tools\ninja.py-Cout\Debug_GN_x64cef-j10ninja:Enteringdirec......
  • 通过groupby将数据分组后提取出来
    groupby真是个好东西参考:python数据分析之Dataframe分组(groupby)_dataframegroupby-CSDN博客【Python】进阶学习:pandas--groupby()用法详解_pandasgroupby函数-CSDN博客get_grouppandas中groupby取出某一组的方法_pandasgroupby分组后取出分组-CSDN博客Python在Python中......
  • WPF GroupBox Expander ExpandDirection="Down" Expander.HeaderTemplate Expander.C
    //xaml<Windowx:Class="WpfApp43.MainWindow"xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"xmlns:d="http://schemas.mic......
  • 归一化技术比较研究:Batch Norm, Layer Norm, Group Norm
    归一化层是深度神经网络体系结构中的关键,在训练过程中确保各层的输入分布一致,这对于高效和稳定的学习至关重要。归一化技术的选择(Batch,Layer,GroupNormalization)会显著影响训练动态和最终的模型性能。每种技术的相对优势并不总是明确的,随着网络体系结构、批处理大小和特定任务......
  • Replication Controller、ReplicaSet和Deployment(Kubernetes调度系列,结合操作命令讲解
    目录一、概述二、ReplicationController2.1ReplicationController说明2.2ReplicationController举例三、ReplicaSet3.1ReplicaSet说明3.2ReplicaSet举例四、无状态应用管理Deployment4.1概述4.2创建Deployment4.2.1Deployment标签内容解析4.2.2ku......
  • Use cases for Rust generics
    Rustprovidesthreemainusagescenariosforgenericparameters,eachwithitsuniquepurposesandadvantages:DelayedBinding:Genericsallowdelayingtheconcretetypebindingofdatastructures,providingflexibilityandcodereusability.Whendefinin......
  • Linux 用户、用户组 useradd、groupadd等详解
    ......
  • Pandas|groupby()
    groupby是Pandas用于根据给定列中的不同值对数据点(即行)进行分组,分组后的数据可以计算生成组的聚合值。agg聚合操作聚合操作是groupby后非常常见的操作,聚合操作可以用来求和、均值、最大值、最小值等.函数用途函数用途min最小值max最大值sum求和mean平......
  • MySQL数据库分组查询group by
    1.DDL建表CREATETABLE`result`(`rid`int(11)NOTNULLAUTO_INCREMENTCOMMENT'成绩编号',`testName`varchar(255)DEFAULTNULLCOMMENT'测试名称',`score`double(4,2)DEFAULTNULLCOMMENT'成绩',`studentId`int(11)DEFAULTNUL......
  • MySQL问题 GROUP_CONCAT
    问题现象CREATEDATABASEtestCHARACTERSETutf8;USEtest;CREATETABLEuser(idINTNOTNULLPRIMARYKEYAUTO_INCREMENT,namevarchar(500),sextinyint(1))ENGINE=InnoDBCHARSET=utf8mb4;#插入500个字节的nameINSERTINTOuser(name,sex)VALUES('111......