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: If select using rownum savs time?

Re: If select using rownum savs time?

From: Daniel Roy <danielroy10_at_hotmail.com>
Date: 9 Apr 2003 06:56:35 -0700
Message-ID: <1b061893.0304090556.30b4359f@posting.google.com>


Perfectly true, as long as it is a "simple" SQL statement (i.e. there is no "ORDER BY" or "GROUP BY" clause, and you don't use "DISTINCT").

Daniel

"music4" <music4_at_163.net> wrote in message news:<b70gug$qid_at_netnews.proxy.lucent.com>...
> Dear Oracle Guru,
>
> I am writing a Oracle application using OCI. I use C++ on Solaris platform.
>
> I have table that contains a huge number of records (over 100000). And I
> need to select first 5000 records. In my current application, I just use
> "select * from the_table", then only petch first 5000 records.
>
> And today, I happened to get know "rownum", so I am guess if "select * from
> the_table where rownum < 5000" would be efficient. Is that true?
>
> Thanks in advance!
> evan
Received on Wed Apr 09 2003 - 08:56:35 CDT

Original text of this message

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