Yes, there is a configurable page cache.  It is a nice feature of Derby that
it does not hog all of the JVM memory by default: it is polite.  You have to
ask it to use more memory.  Also make sure to set –Xmx on the jvm so all the
data fits.  Here is an example:
        stmt.execute("CALL SYSCS_UTIL.SYSCS_SET_DATABASE_PROPERTY(" +
                               "'derby.storage.pageCacheSize'," +
                               "'131072')");

I believe you can also set in derby.properties as well.  If you want to
pre-load the cache, simply query all the rows in the table.

Cheers,
Matt

On 9/1/11 5:33 AM, "鲍少明" <[email protected]> wrote:

> I mean if one table holds a lot of data, then it cannot be all in memory.
> the latest version of hsql of its memory mode allows only keep like 8M data in
> memory but others
>  be kept in disk. This feature looks very useful.
> 
> 2011/9/1 鲍少明 <[email protected]>
>> Hi Guys,
>>  
>> Is there any feature in Derby in its memory mode like Cache table in hsql?
>> I find this feature very important to us , especially there is some table
>> which holds a lot of table,
>> not suitable to be a pure memory table. But I want to still keep the other
>> tables in memory mode.
>>  
>> Is that possible?
>>  
>> Thanks,
>> Clark
> 
> 


iCrossing Privileged and Confidential Information
This email message is for the sole use of the intended recipient(s) and may 
contain confidential and privileged information of iCrossing. Any unauthorized 
review, use, disclosure or distribution is prohibited. If you are not the 
intended recipient, please contact the sender by reply email and destroy all 
copies of the original message.


Reply via email to