can anybody tell us, how to select 2nd max salary from
table.
my id is ashish.akk@gmail.com

Answer Posted / dileep.t

If you need the second highest salary only
then following will also work,

select Max(Salary) from TableName
where Salary not in(
Select Max(Salary) from TableName)

Is This Answer Correct ?    20 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How efficient you are in oracle and SQL server?

823


What is the Control Flow in SSIS

802


What is a sql join?

763


how can u get last observation in an unknown dataset ?

2194


Explain what is raid and what are different types of raid levels?

719


Why olap is used?

731


After removing a table from database, what other related objects have to be dropped explicitly?

806


Explain log shipping and mention its advantages.

795


Explain the rules for designing files and file groups in sql server?

726


how you can move data or databases between servers and databases in sql server? : Sql server administration

713


What is the difference between mysql and mysqli?

770


What is sql profiler. What are the default templates with it? : sql server database administration

715


Explain the microsoft sql server delete command?

715


What is the difference between SQL notification and SQL invalidation?

802


Is candidate a key?

722