Attribute

UnboundedNumericScale (UNS)

Purpose

Specifies the scale for unbounded NUMERIC columns when they are described within the column, parameter, result set, or table metadata. Executing aggregation operations (for example, sum or avg) on bounded NUMERIC columns often results in the server returning the aggregate column as an unbounded NUMERIC column. When this occurs, this option defines the scale for the aggregate column.

Valid Values

x

where:

x
is an integer from -1 to the value set for the Unbounded Numeric Precision connection option.

Behavior

If set to -1, retrieved values are not padded with trailing zeros and not truncated, regardless of how many fractional digits exist.

If set to x, retrieved values with fewer than the specified scale are padded with trailing zeros. The retreived values with more than the specified scale are not truncated and are returned in full.

Notes

  • The driver returns the scale specified in this option for the affected columns regardless of the number of decimal digits in a value.
    • If a value contains fewer digits to the right of the decimal than the specified scale, the remaining digits are automatically returned as padded 0s. For example, if your scale is set to 6 and your value is 22.22, the value returned is 22.220000.
    • If a value contains more digits to the right of the decimal than the specified scale, the fractional digits are not truncated. For example, if your scale is set to 6 and your value is 22.223456789, the value returned is 22.223456789.

Default

-1

GUI Tab

Advanced tab