Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How do I pack a file/reindex within a form
Message
De
07/08/2006 10:32:21
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
07/08/2006 07:42:48
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01143376
Message ID:
01143459
Vues:
15
>Thanks, Tore,
>
>I thought I was missing something, and did not know it's never done!

Doing a PACK every time you delete a record is wrong, for the following reasons:
  • You need exclusive access to the table. This won't work in a multi-user environment.
  • PACK is very slow for large tables.

    Most of the time, you should simply hide deleted records, with the command SET DELETED ON. If you use private datasessions, you must do this in every form (this is easier if you use inheritance).

    You should still do a PACK once a week, once a month, or once a year, to increase performance (too many deleted records will make your application slower).
    Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
  • Précédent
    Suivant
    Répondre
    Fil
    Voir

    Click here to load this message in the networking platform