Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Is SCAN to be avoided?
Message
De
13/11/1999 09:17:12
Walter Meester
HoogkarspelPays-Bas
 
 
À
13/11/1999 04:49:30
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00289152
Message ID:
00290910
Vues:
15
>Srdjan,

>since we are talking about SCAN, If you have to scan through table with let say 100.000 records you will have much better performance having index set
>on 'code' or 'Name' (or whatever) then without any index, right?

It depends..., If about 95% of all the codes or names are the same and you only search for this code or name, you better of without it.

This is precisely the matter with the TAG on DELETED(). If the table contains none or only few deleted records, VFP reads the DELETED() index to filter out records, but it comes to the conclusion that it only can filter out a few deleted() records. After this VFP has to read the records anyway. This makes no sense.

Let's take for example a table that contains a column articleno, If all the values in this column are the same. An index on this column can only degrade performance. The index slows down performance. Just test it and you'll come to the same conclusion.

Regards,

Walter,
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform