How to find 6th highest salary from Employee table ?

Answer Posted / answer

SELECT MIN(SALARY) FROM EMPLOYEE WHERE SALARY IN (SELECT
DISTINCT TOP 6 MAX (SALARY) FROM EMPLOYEE ORDER BY SALARY
DESC)

Is This Answer Correct ?    16 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the difference between clustered and non-clustered index?

538


Explain unique key in sql server?

536


Explain about thread and memory management process of SQL?

532


What are transactions and its controls?

615


What is an identity?

567






What are data regions?

90


What is read uncmmited?

577


What is the significance of null value and why should we avoid permitting null values?

530


Is a primary key unique?

534


Can we use where and having clause together?

506


Tell me what is the stuff and how does it differ from the replace function?

537


What is a view in sql?

578


What is data compression?

545


Why we use functions in sql server?

513


What is the use of attributehierarchyvisible ? : sql server analysis services, ssas

571