项目场景: 最近在部署项目之后,运行出现报错: Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column ‘grades.order_id’ which is not functionally dependent on columns in GROUP BY clause; this is incomp...
1. sql中 union 和 union all 的用法 如果我们需要将两个 select 语句的结果作为一个整体显示出来,我们就需要用到 union 或者 union all 关键字。union (或称为联合)的作用是将多个结果合并在一起显示出来。 union 和 union all 的区别是,union 会自动压缩多个...