How to find the second largest salary in the emp database and
also How to find 3rd,4th and so on ........ in the emp database

plz mail the answer @ mak2786@gmail.com

Answer Posted / harsha

select * from my_table1 where sal not in (select max(sal)
from my_table1) order by Sal desc

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is cached report?

106


How can we use ConnectorJ JDBC Driver with MS SQL?

568


What is the difference between sdf and mdf?

679


What are extended events in sql server?

508


In what sequence sql statement is processed?

585






Explain unique key in sql server?

540


I create a separate index on each column of a table. What are the advantages and disadvantages of this approach? : Sql server database administration

585


What is a print index?

501


as a part of your job, what are the dbcc commands that you commonly use for database maintenance? : Sql server database administration

494


What is difference between rownum and row_number?

519


Can coalesce return null?

547


What is tabulation?

559


List the different normalization forms?

542


What happens if null values are involved in boolean operations?

558


What is the difference between grant and with grant while giving permissions to the user?

511