f2s_table_row_cache¶

Applies to: Oracle, MS SQL, MySql/MariaDB, PostgreSQL Drivers

Syntax

set_attribute f2s_table_row_cache of {FileNumber} to {variable}
get_attribute f2s_table_row_cache of {FileNumber} to {variable}

Parameter

Description

FileNumber

Number of the file (filename.File_Number)

variable

Integer. The number of rows to cache.

Description

Set this attribute during LT or GT finds to only fetch a set number of rows. Note that if the rowcount is set low, too many round-trips to the server may result, effecting performance significantly. Also, if the rowcount is set too high a large number of records can be pre-fetched and end up not being used by the application. Because of this, the default of 10 rows will be adequate for most situations.

Examples

get_attribute

integer iNumber

Get_Attribute f2s_table_row_cache of Customer.File_Number to iNumber

set_attribute

Integer iNumber iNumberAfter

Get_Attribute f2s_table_row_cache of Customer.File_Number to iNumber
Set_Attribute f2s_table_row_cache of Customer.File_Number to 15
Get_Attribute f2s_table_row_cache of Customer.File_Number to iNumberAfter

Showln (SFormat("Before %1, after %2", iNumber, iNumberAfter))

Replaces: Command SQL_FOR_SET