SET_AUTOMATIC_NUMERIC_DATATYPE_REMAPPING¶

Applies to: SQLFlex

This command toggles off and on the automatic numeric data type remapping built into SQLFlex. When adding or creating smaller numeric columns during a restructure, SQLFlex will change the type to a more specific data type i.e. smallint or tinyint since they are handled more efficiently by the server. Sending false to this command will force SQl to keep the column as a numeric field, preserving the length and precision. Passing true will leave the remapping up to the driver.

Syntax

SET_AUTOMATIC_NUMERIC_DATATYPE_REMAPPING to {variable}

Parameter

Description

variable

Boolean variable enabling or disabling remapping

Example

Structure_Start hFile "SQL_DRV"
    Create_Field hFile

    SET_AUTOMATIC_NUMERIC_DATATYPE_REMAPPING to False

    Set_Attribute DF_FIELD_NAME   of hFile iColumn to "Transaction_Count"
    Set_Attribute DF_FIELD_TYPE   of hFile iColumn to DF_BCD
    Set_Attribute DF_FIELD_LENGTH of hFile iColumn to 1
Structure_End hFile DF_STRUCTEND_OPT_NONE "." 0