Watch the 7.3 Webinar On-Demand
This new release brings updates to Universal Storage, query optimization, and usability that you won’t want to miss.

STDDEV_SAMP

Aggregate function. Calculates the sample standard deviation value from a set of numbers. STDDEV_SAMP returns NULL if there are not matching rows.

Syntax

STDDEV_SAMP ( expression )

Arguments

  • expression: any expression. This may be a column name, the result of another function, or a math operation.

Return Type

A double.

Examples

select STDDEV_SAMP(table_rows) FROM information_schema.tables;
+-------------------------+
| STDDEV_SAMP(table_rows) |
+-------------------------+
|           2.1500        |
+-------------------------+
1 row in set (2.87 sec)