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 / prathapshankarshiva

select max(salary) from (select salary from table1 where
salary<(select max(salary) from table1))

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When would you use the stored procedures or functions?

748


What is sharding?

103


Explain the benefits of user-defined functions?

733


Explain view in sql server?

818


How do I install sql server?

622






Explain the microsoft sql server delete command?

701


How to get the definition of a user defined function back?

805


If no size is defined while creating the database, what size will the database have?

744


What is CTE in SQL

706


Explain the types of indexes.

837


What are data driven subscriptions?

95


How will you make an attribute not process? : sql server analysis services, ssas

753


What is difference between order by and group by?

753


What is create statement?

680


How to fine-tune reports?

211