Reading the palm companion guide, there is an 8 byte record entry stored in the record list of the database header. So, for each additional note that you have that is >24 bytes, you automatically gain 8 bytes. The data is stored in a chunk which also has an 8 byte header on it storing lock counts and such, so add another 8 bytes to get you to 16 bytes per extra record.
I think that is it for the overhead per record, and I don't think you can easily change this. Brad "Ryan Bruner" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > > > > I was making updates to my code and decided to attempt to reduce the > amount of memory each record takes up. So, after doing some judicial > rearranging and more efficient use of fields in my data structure, I > reduced what was over 100 bytes to around 65. So, this would seem to > be a 35% reduction in space. > > Now, the catch is that one of the fields, for efficiency sake, is a > string of small size. If, however, the size of the data exceeds the > size of that field (set to 24 bytes now, previously it was 50 bytes), > then I store the data in a data record that ONLY contains the string > information. This "notes" field method allows me to have quick access > to most notes (which tend to be small for my application), but allow > larger notes as well. > > The problem is that after all this conversion, my memory usage, after > conversion of the data from the old format to the new format is > actually no different. It seems that the few additional records added > due to some notes being between 24 and 50 bytes in length added enough > data to basically eliminate any benefit from reducing the memory > footprint of the other 300+ records. > > This seems to indicate that there is a lot of extraneous data > maintained for each record by the PalmOS itself. Is there a way to > make a record not take up as much space from the OS side of things??? > > One might question why I'm not "compacting" the data for each record. > Well, I do some intensive statistical calculations on all of the > records at times, and so using a fixed structure prevents the need for > parsing and copying the data for each record, which speeds things up > dramatically. > > Ryan > > > -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/