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 third highest salary?

Answer Posted / selvaraj anna university coe

In Oracle 9i:
-------------

SQL> SELECT MAX(salary) FROM emp WHERE LEVEL=&no CONNECT BY
PRIOR Salary>salary;


Enter value for no: 3

old 1: SELECT MAX(SALARY) FROM EMP WHERE LEVEL=&no
CONNECT BY PRIOR SALARY>SALARY
new 1: SELECT MAX(SALARY) FROM EMP WHERE LEVEL=3 CONNECT
BY PRIOR SALARY>SALARY

MAX(SALARY)
-----------
500000

SQL>

Is This Answer Correct ?    8 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are group functions in oracle?

1038


What is analyze command used for?

1070


What is meant by recursive hints in oracle?

1084


What is the difference between a user and a schema in oracle?

1034


query optmization techniques and quwry analyser+projects+ppts

2419


How to rename an index?

1071


What is archive log in Oracle?

1131


Explain a synonym?

1026


What is the difference between alert log file and tarce file ?

2167


What is difference between truncate and delete?

1040


Explain database link?

1116


How to sort output in descending order in oracle?

1043


What is an oracle database?

1033


What is pragma autonomous transaction in oracle?

1065


what is difference between sql plus and sql*plus? (not sql and sql plus).

3895