Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
'SCAN FOR' vs 'LOCATE FOR'
Message
De
09/12/1999 22:49:48
 
 
À
09/12/1999 22:35:54
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00301450
Message ID:
00301508
Vues:
29
>
>I am confused here John... and if you have some inside info please share it... but, if there is an index on STATE what does the foxpro engine do different for...
>
>SEEK('PA')
>
>or
>
>LOCATE for STATE='PA'
>
>Seems to me it (the VFP Engine) still has to read the index to determine where the first value of PA is. The only small overhead I see with LOCATE is it has to decide which index to use as opposed to being told.
>
>Unless you are saying that SEEK DOES Sometype of hashing or some type of index magic that LOCATE doesn't do.
>
>I would even guess (no treu knowledge here) that there is a function like FindValueInIndex() that both locate and seek use. Locate just does a bit of stuff first to see which index to use, which takes how long?
>
>Have you benchmarked the speed of Seek Vs Locate? Thanks for providing technical specifics that prove seek is 'MUCH Faster' than Locate.
>
>BOb

Bob,

I tested this several years ago. I don't remember the specific numbers, but can definately tell you that SEEK()/SEEK is faster than LOCATE.
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform