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

find out the second highest salary?

Answer Posted / thananjayan

SELECT * FROM 'emp` WHERE salary < ( SELECT max( salary
)FROM emp ) ORDER BY salary DESC LIMIT 1

This is Mysql syntax, if you use Oracle just remove LIMIT 1
and put it ROWNUM=1;

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Her departmandaki isçilerden empno' su ikinci sirada olan isçilerin empno, deptno, hiredate, sira_no bigilerini döndüren sorguyu yaziniz?

2040


How to export several tables together?

1105


What are set operators?

1136


what are actual and formal parameters?

1159


What is an index associated with a constraint?

1085


What is oracle rowcount?

1143


how can we store any pdf file in oracle

2218


What is a cursor variable?

1213


what is the difference between substr and instr function in oracle?

1142


what are the advantages of running a database in archive log mode?

2252


How to manage transaction isolation level?

1054


How to use existing values in update statements using oracle?

1110


How data locks are respected in oracle?

1109


Explain integrity constraints?

1157


How to use fetch statement in a loop?

1066