In article we will explain how to write a MySQL query to Retrieve highest and lowest salary from the employees table.
Read Also : MySQL Query To Find The Second Highest Salary
Retrieve highest and lowest salary From An employees Table
First let’s create a simple example of employees table. We will populate this table with id, name, salary and department of employees.
SELECT * FROM employees;
The following MySQL statement finds the highest and lowest salary From An employees Table:
SELECT MAX(salary), MIN(salary) FROM employees;