聚合函数

Sum([distinct]<列名>):计算列值总和;

Avg([distinct]<列名>):计算列值平均值;

Max([distinct]<列名>):求列值最大值;

Min([distinct]<列名>):求列值最小值;

Count(*):统计表中元组的格式;

Count([distinct]<列名>):统计本列列值的个数;

注:除了count(*)外,其他的函数在计算过程中都会忽略null值,即null值不会统计。

欢迎批评指正,提出问题,谢谢!
原文地址:https://www.cnblogs.com/xxeleanor/p/14916287.html