SQL Exercise: Find the highest salary from all the employees
SQL employee Database: Exercise-90 with Solution
[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
SELECT max(salary) FROM employees;
max --------- 6000.00 (1 row)
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:
Sample Database: employee
Have another way to solve this solution? Contribute your code (and comments) through Disqus.
Previous SQL Exercise: Employees in ASC order of salary in department 1001.
Next SQL Exercise: Average salary, total remuneration for each type of job.
What is the difficulty level of this exercise?
Test your Programming skills with w3resource's quiz.
- Weekly Trends
- Python Interview Questions and Answers: Comprehensive Guide
- Scala Exercises, Practice, Solution
- Kotlin Exercises practice with solution
- MongoDB Exercises, Practice, Solution
- SQL Exercises, Practice, Solution - JOINS
- Java Basic Programming Exercises
- SQL Subqueries
- Adventureworks Database Exercises
- C# Sharp Basic Exercises
- SQL COUNT() with distinct
- Java Collection Exercises
- SQL COUNT() function
- SQL Inner Join