mysql中常见的分组函数有sum()求和函数、avg()求平均值函数、max()求最大值函数、min()求最小值函数、和count()计算个数函数几种,使用方法如下:
1.sum() 求和
select sum(salary) from employees;
2.avg() 求平均值
select avg(salary) from employees;
3.max() 求最大值
select max(salary) from employees;
4.min() 求最小值
select min(salary) from employees;
5.count() 计算个数
select count(commission_pct) from employees;