Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Speeding up search - Locate For or Seek?
Message
 
 
À
26/07/2000 14:50:51
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00397065
Message ID:
00397251
Vues:
42
>Geo,
>
>Is Rushmore smart enough to re-use the bitmap from your first LOCATE when it does the second LOCATE? Since you're not closing the table in between... maybe?
>
>>>Hey George, I've tried to duplicate your results, but I cannot. With the tag set I'm getting 36 seconds and without it I get .29 seconds. This has always been my experience. There was even a time when it was recommended that you SET ORDER TO 0 before running an SQL, but that's not necessary anymore. Here's how I created my table and how I tested the performance ... I hope I got the UT code formating stuff right.
>>
>>
>>You got me, I have no idea. Here's mine
>>SET ORDER TO TAG GREIGE_NO
>>lnstart = SECONDS()
>>FOR lni = 1 TO 10000
>>  SEEK '439D'
>>NEXT
>>lnstop = SECONDS() && less than 0.2 seconds
>>GO TOP
>>? lnstop - lnstart
>>SET ORDER TO
>>lnstart = SECONDS()
>>FOR lni = 1 TO 10000
>>  LOCATE FOR GREIGE_NO = '439D'
>>NEXT
>>lnstop = SECONDS()
>>? lnstop - lnstart && approx. 6.15 seconds
>>GO TOP
>>SET ORDER TO TAG GREIGE_NO
>>lnstart = SECONDS()
>>FOR lni = 1 TO 10000
>>  LOCATE FOR GREIGE_NO = '439D'
>>NEXT
>>lnstop = SECONDS()
>>? lnstop - lnstart && approx. 2.2 seconds
George,

If I understood David's idea right, try each of this test in a separate program. Run first test, then close VFP session, then second test, then close, then third. Now what are you getting?

Thanks.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform