SQLite Exercise: Get the maximum and minimum salary from employees table
Write a query to get the maximum and minimum salary from employees table.
Sample table : employees
SQLite Code :
SELECT MAX(salary), MIN(salary)
FROM employees;
Output:
MAX(salary) MIN(salary) ----------- ----------- 24000 2100
Relational Algebra Expression:

Relational Algebra Tree:

Practice SQLite Online
Model Database
Structure of 'hr' database :

Improve this sample solution and post your code through Disqus.
Previous: Write a query to get the total salaries payable to employees.
Next: Write a query to get the average salary and number of employees in the employees table.
What is the difficulty level of this exercise?
- Exercises: Weekly Top 12 Most Popular Topics
- Pandas DataFrame: Exercises, Practice, Solution
- Conversion Tools
- JavaScript: HTML Form Validation
- SQL Exercises, Practice, Solution - SUBQUERIES
- C Programming Exercises, Practice, Solution : For Loop
- Python Exercises, Practice, Solution
- Python Data Type: List - Exercises, Practice, Solution
- C++ Basic: Exercises, Practice, Solution
- SQL Exercises, Practice, Solution - exercises on Employee Database
- SQL Exercises, Practice, Solution - exercises on Movie Database
- SQL Exercises, Practice, Solution - exercises on Soccer Database
- C Programming Exercises, Practice, Solution : Recursion