Out of memory in while loop

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
LarsDima
Posts: 4
Joined: Sat 20 Mar 2010 16:50

Out of memory in while loop

Post by LarsDima » Fri 02 Apr 2010 03:16

I open big table for looking all record.
OraTable.Open();
while not OraTable.Eof do
begin
{something action with record}
OraTable.Next();
end;
OraTable.Close();
Table get > 1.000.000 records. Is it possible to clear the buffer after each statement Next

bork
Devart Team
Posts: 649
Joined: Fri 12 Mar 2010 07:55

Post by bork » Fri 02 Apr 2010 11:03

If you are not going to use the Prior method or connect TOraTable to VCL controls which can use this method then you can set the property UniDirectional = True and memory will contain as many records as it is defined in the FetchRows property.

LarsDima
Posts: 4
Joined: Sat 20 Mar 2010 16:50

Post by LarsDima » Sun 04 Apr 2010 04:50

Thanks, it helped

Post Reply