from the table display the 2nd highest salary?
and also the least 2nd salay?

Answer Posted / soorai ganesh

SELECT 'Second Highest Salary Is ', MAX(Salary) FROM Employee WHere Salary < ( Select MAX(Salary) FROM Employee )

SELECT 'Second Least Salary Is ',MIN(Salary) FROM Employee WHere Salary > ( Select MIN(Salary) FROM Employee )

Is This Answer Correct ?    7 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the process of normalising?

752


What is co-related sub query?

733


Your company has 50 branches all over the country all the branches, including the head office have sql server as the database every night all 50 branches upload certain information to the head office which replication topology is best suited for the above scenario?

808


what is database replicaion? : Sql server database administration

812


Explain nested stored procedure. Syntax and an example for create nested stored procedure?

694






What is recursion? Is it possible for a stored procedure to call itself or recursive stored procedure? How many levels of sp nesting is possible?

677


Can select statements be used on views in ms sql server?

766


what is nonclustered index

696


What are the indexes in sql server?

706


What is SQL Server?

844


What is the maximum size of sql server database?

691


Issues related in upgrading SQL Server 2000 to 2005 / 2008

1671


What are the new features of sql server 2008 r2 reporting service?

124


Do you know what are the restrictions that views have to follow?

822


How many null values we can have in a unique key field in sql server?

715