Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Differences between Oracle RDBMS and MS SQL Server
max(column) or min(column)?
-- Niall Litchfield Oracle DBA Audit Commission UK "Tim Kannel" <tdkannel_at_bitstream.net> wrote in message news:MPG.1498d63fbe604b6d9896ae_at_news.bitstream.net...Received on Thu Dec 07 2000 - 10:10:18 CST
> In article <90liu9$862$1_at_nnrp1.deja.com>, oratune_at_aol.com says...
>
> > Perhaps you haven't properly written the query:
> >
> > select empno, dept, sal, hiredate
> > from (select empno, dept, sal, hiredate from emp order by empno)
> > where rownum < 11;
> >
> > For 8i this query will correctly return data for the top 10 empno
> > values. I believe that makes the above a Top-N query.
>
> I might use that type of query if I can't find something better.
> In my opinion, that type of query is an example of a limitation
> in the database server. It shouldn't be that difficult to do
> what should be a fairly simple operation.
>
> BTW, for my purposes I don't need a general top-n solution;
> top 1 would be sufficient. Anyone know of another method
> that would work at least for the top 1 case?
>
> --
> Tim Kannel
> TCAP 3.1 - Captures console I/O to a file
> ftp://ftp.simtel.net/pub/simtelnet/msdos/sysutl/tcap31.zip
![]() |
![]() |