Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Write a query to find second highest salary of an employee.

Answer Posted / manoranjan

to select the nth highest salary from emp table

select distinct(a.sal) from emp a where &n=
(select count(distinct(b.sal))from emp b where a.sal<=b.sal);

Is This Answer Correct ?    3 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to get each name only once from an employee table?

1116


Why we use pl sql?

960


What is a unique key?

1055


What is a natural join sql?

973


What is the difference between the repeatable read and serializable isolation levels? : Transact sql

1101


What are sql triggers used for?

995


How show all rows in sql?

1013


What is dynamic query?

974


What is an escape character in sql?

1025


What is the purpose of the partition table?

1049


What is hibernate and its relation to sql?

1123


define sql insert statement ? : Sql dba

1028


What is fmtonly in sql?

1085


explain primary keys and auto increment fields in mysql : sql dba

977


what is the difference between clustered and non clustered index in sql? : Sql dba

1127