how to find the second highest salary from emp table?

Answer Posted / manvar prajesh

select top 1 name,salary from emp where salary<(select
max(salary) from emp)order by salary desc

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is big data nosql?

512


how to escape special characters in sql statements? : Sql dba

510


What is the max nvarchar size?

515


how would you enter characters as hex numbers? : Sql dba

516


how to do backup entire database? : Transact sql

612






How does postgresql compare to mysql?

573


What is oracle and pl sql?

659


what is 'mysqlcheck'? : Sql dba

573


What does pl sql stand for?

653


Can we insert data into view?

525


What is sql stand for?

573


Can we use join in subquery?

565


What is sap sql?

532


Difference between truncate, delete and drop commands?

557


What is sql*loader and what is it used for?

579