SetTempTableInstance
Mon 01 January 2018Syntax
SetTempTableInstance(instance_number)
Description
Use the SetTempTableInstance function to set the default temp table instance to the specified number for the processing of temporary tables. This default is used by all %Table meta-SQL references to temporary tables, and by all SQL operations. Generally, you use this function only when youâre trying to use any of the ScrollSelect functions, the Rowset class Select or SelectAll methods, the record class SQL methods (SelectByKey, Insert, and so on.), or any of the meta-SQL statements that use %Table (%InsertSelect, %InsertSelectWithLongs, %SelectAll, %Delete, and so on.) Generally, %Table should be used to override the default.
If you use this built-in within an Application Engine program, and the program uses a process-level instance on the request, the old instance value must be saved, then restored after youâre finished using the new instance.
If you pass a zero for instance_number , the Fill method uses the physical table instance with no table append, for example, if the temporary table record is FI_INSTR_T, the physical table used is PS_FI_INSTR_T.
Parameters
Field or Control |
Definition |
---|---|
instance_number |
Specify the instance number for the temporary tables. |
Returns
Existing (or previous) instance number.