Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Indexing unique
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00180757
Message ID:
00180893
Vues:
19
>Oops, my mistake. I think that's a leftover piece of information from FP 2.0 or maybe even FoxBase+.
>
>>I disagree with your statement "Unique indexes aren't maintained." From the help:
>>
>>When a UNIQUE index or index tag is active and a duplicate record is changed in a manner that changes its index key, the index or index tag is updated. However, the next duplicate record with the original index key cannot be accessed or displayed until you reindex the file using REINDEX.

Nancy, Josh and folks,

UNIQUE ndexes are updated dynamically, they always were. The problem is that the nature of what they are causes them to become out of synch with the data over time.

Example: Unique index on customer.state
Situation: 40,000 custoemrs in NY
Actions: 1) delete the one customer in the index, index shows no NY customers
2) reindex, the index still shows no NY customers because the one
that is there is deleted

Actions: 1) change the sate for the one customer in the index
2) the state doesn't show anymore
3) reindex and the state shows again

conclusion: Use unique indexes with caution, when you need one create it, use it, erase it.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform