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

Answer Posted / mehul

for 2nd highest salary

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


for 2nd least salary

select min(salary) from employee where salary>(select min
(salary) from employee )

i hope that will help you

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the difference between primary key and unique key? : sql server database administration

701


What are the 3 types of schema?

780


What do you mean by collation recursive stored procedure?

781


what number files will a information contain in SQL Server? How many forms of information files exist in SQL Server? How many of those files can exist for a single database?

728


What are data regions?

107






What are the differences between DDL, DML and DCL in SQL?

941


what protocol both networks use? : Sql server database administration

715


You want to implement the one-to-one relationship while designing tables. How would you do it?

719


What is temporal data type?

659


What is the difference between substr and charindex in the sql server?

683


Is sql server implemented as a service or an application? : Sql server database administration

700


What is field in algebra?

788


Can primary key be null?

681


What is difference between rownum and row_number?

692


How to find which stored procedure is currently running in sql server?

669