Site Owners Forums - Webmaster Forums

Site Owners Forums - Webmaster Forums (http://siteownersforums.com/index.php)
-   PHP / mySQL (http://siteownersforums.com/forumdisplay.php?f=10)
-   -   Write an SQL query to get third maximum salary of an employee from a table named empl (http://siteownersforums.com/showthread.php?t=357572)

Pavan Techn 06-01-2018 10:16 AM

Write an SQL query to get third maximum salary of an employee from a table named empl
 
SELECT TOP 1 salary
FROM (
SELECT TOP 3 salary
FROM employee_table
ORDER BY salary DESC ) AS emp
ORDER BY salary ASC;


All times are GMT -7. The time now is 06:03 PM.


Powered by vBulletin Copyright © 2020 vBulletin Solutions, Inc.