Posted by Barbara Brazil on May 07, 2013 at 10:26:09:
In Reply to: Any ideas on these issues? posted by Bob A on May 07, 2013 at 06:46:49:
Sorry, Bob, but you lost me with your first post about this. Despite that, I will offer some advice...
First, "rightful place in byte zero"?? Even though a lot (most?) programmers put the record's key info at the beginning of the record that really isn't the best place for it. The file system uses the first few bytes of deleted records to build a chain of them so the space consumed by the deleted records can be reassigned as new records are added to the file. If you put the key there and then decide soon after that you goofed by deleting the record(s), you've lost probably the most important info in the record! See below for a thread with a more complete discussion of this.
Next, extended keyed files and multi-keyed files... Extended keyed files are keyed files where the entire key info is included in the record data. In legacy keyed files this wasn't required. This made rebuilding the key tree difficult if not impossible if required. Extended keyed files also allow for a larger key size. Here's more info about the advantages of Extended Keyed Files. As far as we're concerned, extended keyed files are all you should use. Multi-keyed files are an option of extended keyed files. They allow you to retrieve the records very quickly via more than one key. When setting up the secondary keys you may find that you will repeat some of the key information more than once in the record. If at first this seems inefficient, consider this example. Say the primary key of your order header file is by order number. You setup 2 secondary keys so you can quickly get the records in order by customer number and by salesman number. For each of the secondary keys you want them sorted by order number within their main sort. To do this you'd need key fields of (customer number + order number) and (salesman number + order number) in your record. Note that order number will occur in the record more than once.
I'm not sure this is even what you were asking about but I hope it helps.
Each file can be a maximum of 1MB in length Uploaded files will be purged from the server on a regular basis.