ubject: Re: Efficiency of VFSImportDatabaseFromFile
From: "Larry Johnson" <[EMAIL PROTECTED]>
Date: Tue, 26 Jul 2005 21:35:07 -0000

Spare memory went from 800K to 5.7M, merely by partitioning the data as you suggested. I'm taking baby steps and am packing just 20 records at a time.

I would like to be able to determine how many actual records are in a packed pdb. So I need a definitive way to determine the size of a record. The number of actual records in the last pdb record could be determined by: PdbRecordSize / ActualRecordSize;

DmQueryRecord returns a MemHandle, and I thought about calling MemHandleSize. But I'm not sure if this is accurate. I need to know the size of the last record (which packs several actual records). Any help?

MemHandleSize is very accurate, but to use it assumes that you only allocated as much memory as you required on the last block.

So ultimately how you write out the last partial block determines how you can figure out how many records are present in it.



Roger Stringer
Marietta Systems, Inc. (www.rf-tp.com)


--
For information on using the PalmSource Developer Forums, or to unsubscribe, 
please see http://www.palmos.com/dev/support/forums/

Reply via email to