ICriteriaCursor<T> iteration stop after 50 occurences

I have a problem using ICriteriaCursor when i loop on it, it does not fetch all record in my entity table but only 50.
Here is my code
procedure TAPRRHistoriqueintegrationParser.process;
MyCriteria: TCriteria;
Cursor: ICriteriaCursor;
trans: TaprrTransaction;

MyCriteria := manager.find;
Cursor := MyCriteria.Open;

while HistoriqueCursor.Next do

trans := HistoriqueCursor.Get;


Table containing TaprrTransaction entities has mode than 80000 row. But the loop always exit after 50 occurences.

Am i doing something wrong ? I don't understand why it does not loop the entire table.

Could you Help ?


You don't say what database access library you're using, but my guess is that the underlying query may have a 50 record buffer. I use Devart IBDAC and it has a 25 record buffer - setting the query property FetchAll to true results in all records being returned. Could something similar be happening here, with the iteration only running over the retrieved records?

I'm Using FireDac Mysql Driver.
I changed my driver settings to "Fetchall" for cursor. Now Everything is OK.

Thanks for your support

1 Like

This topic was automatically closed 60 minutes after the last reply. New replies are no longer allowed.