PDA

Click to See Complete Forum and Search --> : Reading Record Set too slow


Geoff Gunson
Nov 10th, 1999, 06:18 PM
Hi

I am reading a RS with minimum of about 1000 records. To move through the entire RS takes about 23 seconds for 1003 records or put it another way 0.02 seconds per record. What I have done is to open the RS using the SELECT method only retriving the feilds I am interested in. Then I setup a loop...

Do While not RS.EOF
RS.movenext
Loop

Am I doing something wrong? How can I speed up my process.

Thanks for your time

Geoff

Ishamel
Nov 10th, 1999, 07:52 PM
This loop can be used instead of the Do..Until EOF.

It is supposed to be about 30% quicker, because it does not have to check the .EOF property each time it loops.


Dim iEOF as Long


rsRecordSet.MoveLast
iEOF = rsRecordSet.RowCount
rsRecordSet.MoveFirst


For iTurns = 1 To iEOF
rsRecordSet.MoveNext
Next




[This message has been edited by Ishamel (edited 11-11-1999).]