Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
To PACK, or not to PACK that is the question
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00017947
Message ID:
00017976
Views:
70
>whether 'tis nobler in the application
>to suffer the slings and arrows of insufficient disk space...
>
>----------------------------
>
>PACK is not a good idea, we know this. I learned it early on when my application ran out of disk space during a PACK and lost the original and the copy tables - not a happy experience.
>
>SO the normal action is to check for sufficient disk space, then COPY TO a temporary file FOR NOT DELETED(). Then to reindex that file. Finally rename your table and CDX to a backup name (just in case) and rename your copy back tp the original.
>
>Lovely - but has anyone written a class or procdure to do this for a VFP table that is part of a database?
>
>I'm starting out on this escapade and don't want to reinvent the wheel.

Who runs out of diskspace now a days? I created an index tag for deleted() and only pack those tables that have a deleted record. I believe this is the only time pack is really necessary. Also, remember to PACK MEMO if U have a memo file. I forgot and ended up with a 10MB FPT file one time. Personally, I have never heard of the problem U are experiencing. It does sound scary though. Would having the fox temp files stored/created on a local drive with suffucient diskspace eleviate this potential problem? The question also is who much diskspace is enough for Fox temp files during a PACK? 1/2x or 1/3x the size of the DBF? Also, could U just use diskspace() before attempting a pack? Please keep this thread alive if you confirm this is a problem. htwh. Steve
Steve Medvid
Systems Analyst

Environmental Resource Management
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform