Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within Oracle/OAS
Search Coderanch
Advance search
Google search
Register / Login
Post Reply
Bookmark Topic
Watch Topic
New Topic
programming forums
Java
Mobile
Certification
Databases
Caching
Books
Engineering
Micro Controllers
OS
Languages
Paradigms
IDEs
Build Tools
Frameworks
Application Servers
Open Source
This Site
Careers
Other
Pie Elite
all forums
this forum made possible by our volunteer staff, including ...
Marshals:
Campbell Ritchie
Tim Cooke
Ron McLeod
paul wheaton
Jeanne Boyarsky
Sheriffs:
Paul Clapham
Devaka Cooray
Saloon Keepers:
Tim Holloway
Roland Mueller
Himai Minh
Bartenders:
Forum:
Oracle/OAS
find second largest value in a column
rakesh repala
Greenhorn
Posts: 5
posted 16 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
please help me find the second largest value in a column
write a query using oracle 8i
rakesh
Jan Cumps
Bartender
Posts: 2662
19
I like...
posted 16 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Hi Rakesh,
Did you try to write such a query yourself?
Can you show us how far you got?
Regards, Jan
OCUP UML fundamental and ITIL foundation
rakesh repala
Greenhorn
Posts: 5
posted 16 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
select sal from emp e1 where 2=(select count* from emp e2 where e1.sal>e2.sal)
regards
------
rakesh
pradeep singh
Ranch Hand
Posts: 339
posted 16 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Hi
Select sal from (select max(sal) from emp)
where ROWCOUNT<=1
order by sal desc
I think it will work fine to get second highest salary .
SCJP 5.0(75%), SCWCD 5.0(88%)
reply
reply
Bookmark Topic
Watch Topic
New Topic
Boost this thread!
Similar Threads
Autoresizing table column
arrays?
sql query
Finding Nth Largest element of an array without sorting
second maximum value from the array
More...