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 get 2nd maximum salary in an employee table ?

Answer Posted / priya

select rownum,empno,sal from (select
rownum,empno,sal from emp order by sal desc) group
by rownum,empno,sal having rownum=2;


This will clearly work.............

Is This Answer Correct ?    6 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why do we need cursors in pl sql?

1091


What is difference between hql and native sql?

1178


Can you selectively load only those records that you need? : aql loader

1050


Is natural join same as inner join?

948


What is the use of function in sql?

1099


When to use inner join and left join?

963


What are basic techniques of indexing?

1388


Enlist the data types that can be used in pl/sql?

1074


how to include comments in sql statements? : Sql dba

962


What is count * in sql?

1001


How do I remove all records from a table?

1081


What is the use of prepared statement?

1029


what is the difference between a having clause and a where clause? : Sql dba

1092


what is auto increment? : Sql dba

1015


Can we create a trigger on view?

901