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 / dev anand s

select salary from (
select salary, dense_rank() over(order by salary desc) rank from emp) where rank=2;

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is sql and how does it work?

1163


Can a foreign key be a duplicate?

905


Why trigger is used in sql?

964


Does sqlite need a server?

1042


What do you know by pl/sql cursors?

1099


Explain what is table in a database?

1055


Why is sql*loader direct path so fast?

1099


Can we create index on primary key?

961


What is the purpose of using pl/sql?

1138


What is sql mysql pl sql oracle?

1067


What is a primary key example?

956


Why we use cross join?

950


What are dml commands?

1019


What is sql injection owasp?

1058


What is sql*loader?

1176