Difference between revisions of "SET GCACHE"
Yvonnemilne (Talk | contribs) |
Helengeorge (Talk | contribs) (→Products) |
||
(7 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
==Purpose== | ==Purpose== | ||
Enable or disable shared table and index file caching | Enable or disable shared table and index file caching | ||
Line 15: | Line 8: | ||
==See Also== | ==See Also== | ||
− | SET CACHELOAD, SET DCACHE, SET ICACHE, SET PCACHE | + | [[SET CACHELOAD]], [[SET DCACHE]], [[SET ICACHE]], [[SET PCACHE]] |
Line 27: | Line 20: | ||
==Example== | ==Example== | ||
− | < | + | <code lang="recital"> |
// Open up payroll system | // Open up payroll system | ||
set cacheload on | set cacheload on | ||
Line 33: | Line 26: | ||
set icache to 3000 | set icache to 3000 | ||
set dcache to 1000 | set dcache to 1000 | ||
− | use payroll index pay_date, emp_code</ | + | use payroll index pay_date, emp_code</code> |
==Products== | ==Products== | ||
− | Recital | + | Recital Server, Recital |
[[Category:Documentation]] | [[Category:Documentation]] | ||
[[Category:Commands]] | [[Category:Commands]] | ||
− | [[Category:Set_Commands]] | + | [[Category:Set_Commands|GCACHE]] |
+ | [[Category:Performance and Optimization]] | ||
+ | [[Category:Performance and Optimization Set Commands]] |
Latest revision as of 15:57, 23 November 2009
Purpose
Enable or disable shared table and index file caching
Syntax
SET GCACHE ON | OFF | (<expL>)
See Also
SET CACHELOAD, SET DCACHE, SET ICACHE, SET PCACHE
Description
The SET GCACHE (global cache) command allows table and index file caching on shared tables. The SET DCACHE and ICACHE commands cause table records and index files to be ’cached’ in memory. Normally these commands only operate on tables that have been opened exclusively. When SET GCACHE is ON, the DCACHE and ICACHE commands handle caching on a distributed basis.
The number of records cached is specified with the SET DCACHE command. When SET GCACHE is ON, the number of records specified by the SET DCACHE command is reserved on a per user basis. Caching table records and index files accelerates only those I/O operations that access the cached records. Operations such as a sequential read of a table, or a random query, will not benefit from caching. The SET GCACHE command can be used in conjunction with the SET DCACHE and SET PCACHE commands to optimize performance.
The SET CACHELOAD command may be used with the DCACHE command to forcibly load the table and index cache into memory when the table is used. Although this can be a lengthy process, further access to the table is accelerated dramatically.
Example
// Open up payroll system set cacheload on set gcache on set icache to 3000 set dcache to 1000 use payroll index pay_date, emp_code
Products
Recital Server, Recital