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

Home -> Community -> Usenet -> c.d.o.misc -> Re: how to find "bottom" of table in a group query

Re: how to find "bottom" of table in a group query

From: Matthias Gresz <GreMa_at_t-online.de>
Date: Thu, 04 Mar 1999 08:09:52 +0100
Message-ID: <36DE31C0.AC0C783B@t-online.de>

Jonathan Lewis schrieb:
>
> For details on the last possible timestamp
> per staff_id_no, the following should work:
>
> select *
> from region_log r1
> where (r1.staff_id_no, r1.timestamp) in
> (Select r2.staff_id_no, max(r2.timestamp)
> from region_log r2
> where r2.timestamp > sysdate-1
> group by r2.staff_id_no
> )
>
> As others have pointed out,though, there is no
> 'nice' solution to general 'bottom 10'/'top 10' problem.
>

I disagree:
check out dejanews archive for Jurij Modics TOP X solution posted here last year!

HTH
Matthias
--
grema_at_t-online.de

Es gibt nichts Neues mehr.
Alles, was man erfinden kann, ist schon erfunden worden. Charles H. Duell, Leiter des US Patentamtes bei seinem Rücktritt 1899 Received on Thu Mar 04 1999 - 01:09:52 CST

Original text of this message

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