Aggregate function that calculates the minimum across a group of values.


SELECT min(salary) FROM employees;
SELECT department, min(salary) FROM employees GROUP BY department;

If you need non-aggregate function to choose a minimum of two values, see least:

SELECT least(a, b) FROM table;

Rating: 1.6 - 53 votes

Was this content helpful?