Slow updaterecord loop

jda jda at his.com
Thu Apr 21 15:38:00 CDT 2005


>>>
>
>why do you use
>
>Ende=myCursor.NumberOfRecords
>For i=1 to Ende
>        myCursor.CurrentPosition
>        myCursor.LongField("hit").value = i
>        myCursor.updateRecord
>next
>
>this is out of my thoughts. Coding could be alittle bit different. 
>Isn't this faster?
>

Hi Claudius,

Thanks for the suggestion. It may be a few ticks faster, but no more. 
Still about 20 seconds. The problem is with the size of the cursor, I 
guess, not minor improvements in looping.

Parenthetically, the reason I retrieve 61 fields is  because this is 
an SQL search being done directly by users, and if they do "ORDER BY" 
I need all my sortmethod fields available (it's too painful and prone 
to error to parse their SQL to try to see what might be needed). 
If/when the ability to sort on fields and methods that are NOT 
retrieved in the search, as discussed on this list, would make this 
entirely unnecessary.

Jon


More information about the Valentina-beta mailing list