StdDev

Description

Calculates the standard deviation of an aggregation of values.

Syntax

StdDev ( n )

Arguments

n is a numeric expression.

Example

Returns the average and standard deviation of each continent's female population.

select Continent, Avg(Pop_Fem) as Average, StdDev(Pop_Fem) as StandardDeviation from countries group by Continent
			

Remarks

StdDev is an aggregation function which can only be used in an aggregating Select statement. Null values are ignored. If there are only null values supplied in the aggregation, then a null value is returned.