Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Sql Query

Re: Sql Query

From: <sigdock_at_my-deja.com>
Date: Wed, 22 Nov 2000 15:12:29 GMT
Message-ID: <8vgnom$of0$1@nnrp1.deja.com>

Try the following query:

select id
, total
from orders
where rownum < 5
order by total desc
/

Should work...

h.t.h.

BertJan Meinders
Oracle DBA
ASR-ICT In article <8vgltk$mq3$1_at_nnrp1.deja.com>,   Paul <elrik13269_at_my-deja.com> wrote:
> Hi,
> I,m new to sql and wonder if anybody could help me with the following:
> If I had a table with say order id and order total i.e
>
> id total
> 213 567.35
> 345 444.00
> 214 32.99
> and so on how would I find say just the fourth highest total from the
> table without displaying the rest of the table.
> Thanks for any help.
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
>

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Wed Nov 22 2000 - 09:12:29 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US