hi Tore,
Probably,
Just did a test both with data on a local system and data residing on a server
Table 450,000 records
index active
loop of 1 to 1000,000
set Talk Off (On slows down locate)
And you know what ? Locate turns out to be the slower (about twice the time of go top)
See also
http://fox.wikis.com/wc.dll?Wiki~VFPBasicDataConcepts~VFP There's a statement from Mike Yearwood
quote
GO TOP
to accomplish the same thing. Some people say that's a bit slower than a naked LOCATE. With all but the biggest tables, the speed difference is not detectable by humans.
unquote
Although I have never done any tests on huge tables, I have no doubts about locate being faster.
For smaller tables I have my doubts. I've never seen a penalty using go top
___________________________________
>Hi Gregory,
>
>with a big table and the correct index, the difference can be enormous. GO TOP can take minutes, LOCATE takes a few microseconds.
>
>>>>>Hi
>>>>>
>>>>>Is there any way to tell if a filter results in 0 records?
>>>>>
>>>>>Thanks
>>>>>
>>>>>Colin
>>>>
>>>>Something like
>>>>
>>>>
>>>>go top in AliasName
>>>>
>>>>ZeroRecords = eof('AliasName')
>>>>
>>>
>>>I think 'locate' would be better as it's Rushmore optimizable.
>>>Cetin
>>
>>Yeah, perhaps. I've never done any test, so I don't know how much of a difference there's involved
Gregory