SQL Exercise: Find the highest salary from all the employees
[An editor is available at the bottom of the page to write and execute the scripts.]
90. From the following table, write a SQL query to find the highest salary. Return highest salary.
Sample table: employees
Sample Solution:
SELECT max(salary)
FROM employees;
Sample Output:
max --------- 6000.00 (1 row)
Explanation:
The said query in SQL selects the maximum value of the salary column from the employees table. The MAX() function is used to retrieve the highest value of the salary column.
Relational Algebra Expression:

Relational Algebra Tree:

Go to:
PREV : Employees in ASC order of salary in department 1001.
NEXT : Average salary, total remuneration for each type of job.
Practice Online
Sample Database: employee

Have another way to solve this solution? Contribute your code (and comments) through Disqus.
What is the difficulty level of this exercise?
Test your Programming skills with w3resource's quiz.