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

Home -> Community -> Usenet -> c.d.o.tools -> fetch by array

fetch by array

From: <eastking_at_my-deja.com>
Date: Wed, 04 Oct 2000 02:50:51 GMT
Message-ID: <8re5ub$v7q$1@nnrp1.deja.com>

hello,every one here.

I am using Oracle 8. When I fetch data by array , I meet a problem as following .Please help me.

    curSelect integer;
    CodeArray1 dbms_sql.Varchar2_table;
    CodeArray2 dbms_sql.Varchar2_table;
    nCount integer;@@
    dbms_sql.parse(curSelect,

                   'select

...
...
from ...', dbms_sql.v7);

    dbms_sql.define_array(curSelect,1,CodeArray1,10,indx);     dbms_sql.define_array(curSelect,2,CodeArray2,10,indx);

...
...;

    execute_select = dbms_sql.fetch_rows(curSelect);     loop

       nCount := dbms_sql.fetch_rows(curSelect);
       dbms_sql.column_value(curSelect,1,CodeArray1);
       dbms_sql.column_value(curSelect,2,CodeArray2);
                   ...
                   ...;
       exit when nCount != 10;

   end loop;

When I use CodeArray1 and CodeArray2, I found that never did the data in CodeArray1 or CodeArray2 be overriden by next fetch.It just increase it's indx one by one. Because I have almost 200 thousands records in a table, it seemed to be a problem with memory. How can I solve it. Thanks in advance.

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Tue Oct 03 2000 - 21:50:51 CDT

Original text of this message

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