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: Query results over 200 000 Records ?!?!!??!

Re: Query results over 200 000 Records ?!?!!??!

From: Karsten Farrell <kfarrell_at_belgariad.com>
Date: Mon, 25 Nov 2002 17:55:46 GMT
Message-ID: <CutE9.60$No5.6739047@newssvr21.news.prodigy.com>


Filiz Duman wrote:
> Hi All,
>
> I was just wondering what can I change in my code, database set-up, table
> set-up
> if I want to run a query which returns usually over 200 000 records.
>
> I am actually using the Apache web server with Oracle 8.1.7 database and a
> web front end (created with database packages PLSQL), but since the query
> does take a very long time to execute (20 min) the user is unable to see the
> results on the web page.
>
> Any ideas ?
>

Your client submits the PL/SQL to the database. Oracle churns away, grabbing all 200,000 rows. It has no idea that you only want one (or a few) rows to display on your web page. So your users have to wait for Oracle to finish before they see a single web result (maybe you even threw a sort in there to order the output).

You have to modify your query to return a smaller result set (so the backend Oracle can grab your data quickly). There are a variety of ways to accomplish this. Things like returning 20 rows at a time. Received on Mon Nov 25 2002 - 11:55:46 CST

Original text of this message

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