Free Disk Necessary To Retructure A File
Bob Stockler
bob at trebor.iglou.com
Mon Jul 28 18:25:37 PDT 2008
Ken Brody wrote (on Mon, Jul 28, 2008 at 06:24:34PM -0400):
| Quoting Bob Stockler (Mon, 28 Jul 2008 18:01:53 -0400):
|
| > Ken Brody wrote (on Mon, Jul 28, 2008 at 04:35:53PM -0400):
| [...]
| > | >Could not the shrinking filePro program have been written to
| > | >write the shortened records starting at the beginning of the
| > | >existing key file, then write free records to the balance of
| > | >the space occupied by the file? This would result, according
| > | >to how much the records were being shortened, in it being just
| > | >a few bytes larger than it originally was.
| > |
| > | What about all the records that will also be added to the other segment?
| > | (ie: the data segment if modifying fields in key.)
| >
| > Well, if anyone still uses a data segement, the same apply to it.
| > It would result in the data segment being perhaps a few bytes longer.
|
| Consider this scenario:
|
| File has 100,000 records.
| Key record length is 1K.
| Data record length is 5K.
|
| You shrink the key record by 5 bytes. This means that you need to add
| 500 records to keep the key file the same size. That also means that
| the data segment will increase by 2.5MB. (Not much in today's terms,
| but hardly "a few bytes".)
Stupit file layout, but possible (though dumb, Dumb, DUMB).
| > It all depends on whether there was, or was not, a data segement,
| > and where the fields being shortened or eliminated existed.
| >
| > I can envision this being used much more (if at all, ever) anyway.
|
| I assume you mean "can't"?
Actually, "can not" ;-}
Bob
PS - My filePro "deflate" program can merge Key and Data files
into one Key file, remove empty records, leaving one free
record at the end of the filePro file, and truncate the
Key file appropiately on many UNIX, Linux and Windows
systems (if they have Perl installed).
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file,
into one key file, remove empty records, leaving one free
record at the end of the filePro file, ey file, remove empty records, leaving one free
record at the end of the filePro file,
--
Bob Stockler +-+ bob at trebor.iglou.com +-+ http://members.iglou.com/trebor
More information about the Filepro-list
mailing list