Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: Basic SQL question I think
select * from
(select A from TABLE order by A desc) where rownum < 11;
I think that is right, they had a discussion about this not so long back, but it's archived now..
Regards
Mark
-----Original Message-----
From: root_at_fatcity.com [mailto:root_at_fatcity.com]On Behalf Of
nlzanen1_at_ey.nl
Sent: Thursday, January 18, 2001 02:12
To: Multiple recipients of list ORACLE-L
Subject: Basic SQL question I think
Hi All,
I guess I'm braindead already (not even friday yet)
I have a table with two columns
column A number
column B varchar2
I need to have the top ten numbers from this table (column a)
The numbers are in random order.
I have tried all sorts of stuff with ordering etc but to no avail.
Anybody feeling lucky??
TIA
Met vriendelijke groet,
Jacob van Zanen
(Oracle DBA) Informatie Systemen
Ernst & Young
Informatie & Communicatie Technologie
Kantoor Gouda
Tel.: 0182 575316 (intern: 923 316)
Fax: 0182 536311
E-mail: nlzanen1_at_ey.nl
Indien bovenstaand e-mailbericht niet aan u is gericht, verzoeken wij u vriendelijk doch dringend het e-mailbericht te retourneren aan de verzender en het origineel en eventuele kopieën te verwijderen en te vernietigen.
Ernst & Young hanteert bij de uitoefening van haar werkzaamheden algemene voorwaarden, waarin een beperking van aansprakelijkheid is opgenomen. De algemene voorwaarden worden u op verzoek kosteloos toegezonden.
If you are not the intended recipient of this communication please return the communication to the sender and delete and destroy all copies.
In carrying out its engagements, Ernst & Young applies general terms and conditions, which contain a clause that limits its liability. A copy of these terms and conditions is available on request free of charge.
-- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: INET: nlzanen1_at_ey.nl Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051 San Diego, California -- Public Internet access / Mailing Lists -------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You mayReceived on Thu Jan 18 2001 - 08:53:59 CST