mirror of
https://github.com/hanzoai/datastore.git
synced 2026-09-26 13:55:07 +00:00
386 B
386 B
toc_priority
| toc_priority |
|---|
| 3 |
max
Aggregate function that calculates the maximum across a group of values.
Example:
SELECT max(salary) FROM employees;
SELECT department, max(salary) FROM employees GROUP BY department;
If you need non-aggregate function to choose a maximum of two values, see greatest:
SELECT greatest(a, b) FROM table;