PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN

This content has been translated automatically. Click here to view the French version.
  • Retrieving the records
  • Management of Property CtCacheSize
  • hQueryWithoutCorrection constant
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
CtCacheSize (Property)
In french: CxTailleCache
OLE DBNative Connectors (Native Accesses)Available only with these kinds of connection
The Property CxTailleCache allows to know and modify the maximum number of records that can be contained in the cache of the Native Connector MySQL.
Remark: The cache size specified with the Property CxTailleCache is ignored if this size was specified directly in the optional information of the HDescribeConnection or HOpenConnection functions.
Managing the cache: operating mode
Each time an external database is accessed, the recovered records are stored in the cache of the Native Connector used before being transmitted to the client workstation..
The cache of an Native Connector can only contain a limited number of records.. If the number of records to retrieve is greater than the maximum number of records defined for the cache, the records are retrieved in batches.
The maximum number of records that can be stored in the cache corresponds to the size of the cache.
For example, if the size of the Native Connector cache used is equal to 10, when executing a query selecting 24 records, the cache will fill 3 times in a row:
  • 10 records.
  • 10 records.
  • 4 records.
Example
// Change the size of the Native Connector MySQL cache used by the MyConnection
MyLogin.CxCacheSize = 450
Syntax

Knowing the size of the Native Connector MySQL cache Hide the details

<Cache size> = <Connection name>.CtCacheSize
<Cache size>: Integer
Size of the Native Connector MySQL cache.
If this parameter corresponds to:
  • -2: the cache size is the size per Default (100 for the Native Connector MySQL).
  • -1: the size of cache is unlimited.
  • 0: the cache stores no record. No record is retrieved.
<Connection name>: Character string (with or without quotes)
Name of connection used. This name was defined in the data model editor, or by HDescribeConnection or HOpenConnection.

Change the cache size of the Native Connector MySQL cache Hide the details

<Connection name>.CtCacheSize = <Cache size>
<Connection name>: Character string (with or without quotes)
Name of connection used. This name was defined in the data model editor, or by HDescribeConnection or HOpenConnection.
<Cache size>: Integer
New cache size for Native Connector MySQL.
If this parameter corresponds to:
  • -2: the cache size will be the size by Default (100 for the Native Connector MySQL).
  • -1: the size of the cache will be unlimited.
  • 0: the cache will store no record. No record will be retrieved.
Remarks

Retrieving the records

The speed at which the entire set of records is retrieved is proportional to the size of the cache: the larger the cache size, the faster the records are retrieved.
However, the smaller the cache size, the faster the first record will be read.
Caution: The memory used by the cache is proportional to the size of the cache.

Management of Property CtCacheSize

The Property CtCacheSize is managed only by the Native Connector MySQL.
The other Native Connectors s do not manage the CtCacheSizeproperty. . In this case, the use of this property will be ignored and no error will be generated.

hQueryWithoutCorrection constant

If the query is executed without checking the SQL code (using the constant hQueryWithoutCorrection), the size of the cache will be unlimited and cannot be modified thanks to the Property CtCacheSize.
See also
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment