median
Descriptionβ
The MEDIAN function returns the median of the expression.
Syntaxβ
MEDIAN(<expr>)
Parametersβ
Parameters | Description |
---|---|
<expr> | The expression needs to be obtained |
Return Valueβ
Returns the same data type as the input expression.
Exampleβ
select median(scan_rows) from log_statis group by datetime;
+---------------------+
| median(`scan_rows`) |
+---------------------+
| 50 |
+---------------------+