Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
好的,所以我有一个按功能分组,按 Y 分组。
分组可能有 5 个不同的值:A、B、C、D、E。然后我将如何将相同的值按另一个值分组,所以如果我有 2 个数据值返回为 A,怎么办我将它们进一步分组?
GROUP BY Y GROUP BY X (WHERE column1=column1)?
您可以添加由分隔的多个列,
,
select a, b, c, avg(d) from mytable group by a, b, c;