Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
CDX size bloating on large number of INSERTs
Message
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00495402
Message ID:
00495428
Vues:
11
>Just a guess here...
>
>But as your adding (INSERTing) truckloads of records, VFP is constantly updating the internal tree structure of the keys in the CDX. After INSERTing tens of thousands of records, it may feel it has to rebalance the tree and it may rebuild it at the end of the file and just leave the original tree structure intact (but unavailable) at the beginning of the CDX, therefore taking up space.
>
>I'll bet the REINDEX (and also INDEX ON) are more efficient since they both know how many records there are to index up front and therefore can make a better prediction as to how to structure the tree up front; therefore, the final CDX is "tighter".
>
>Of course, I may be completely wrong... it's just an educated guess. It's been a looooonnnng time since I've studied CDX behavior.

No that is definitely worth a point... *smile*

Yeah, so if I just wait to reindex until I am done, it might work better. Plus, I probably won't lose much time since the INSERTs will all be a hair faster without the need to index.

It is interesting to notice pauses as records are added or reindexed. I always assumed it was just VFP moving around memory internally or paging stuff out, but maybe the pauses are due to serious internal reconstruction of some of the file guts. Very interesting food for thought.

Thanks!

JoeK
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform