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...

how to find the second highest salary from emp table?

Answer Posted / susanta

select * from emp e1 where N-1 =
(select count(distinct sal)
from emp e2
where e2.sal > e1.sal)
for Nth highest salary.

Is This Answer Correct ?    20 Yes 11 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do I view tables in mysql?

915


What does the base_object_type column shows in the user.triggers data dictionary view?

996


How do you add a column to a table?

995


what is the command line end user interface - mysql? : Sql dba

925


What is db journal file?

956


What is primary key and unique key?

1049


Differentiate between syntax and runtime errors.

1119


Determine if oracle date is on a weekend?

981


What port does sql server use?

986


How do you write a complex sql query?

1007


What is sql in oracle?

1002


What is sql injection vulnerability?

870


What is difference between sql and oracle?

1047


What is primary and foreign key?

1015


Can a table contain multiple foreign key’s?

948