Results of a FORMAT Phrase Defining Too Few Positions | Teradata Vantage - Results of a FORMAT Phrase Defining Too Few Positions - Teradata Vantage - Analytics Database

SQL Data Types and Literals

Deployment
VantageCloud
VantageCore
Edition
VMware
Enterprise
IntelliFlex
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
ft:locale
en-US
ft:lastEdition
2025-11-06
dita:mapPath
uds1628112204571.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
exs1472253032394
lifecycle
latest
Product Category
Teradata Vantage™
A FORMAT phrase that defines fewer positions than are required by numeric values causes the data to be returned as follows:
  • Asterisks appear when the integer portion cannot be accommodated.
  • When only the integer portion can be accommodated, any digits to the right of the least significant digit are either truncated (for an integer value) or rounded (for a floating, number, or decimal value).

Rounding is based on “Round to the Nearest” mode, as illustrated by the following process.

  1. Let B represent the actual result.
  2. Let A and C represent the nearest bracketing values that can be represented, such that A < B < C.
  3. The determination as to whether A or C is the represented result is made as follows
    1. When possible, the result is the value nearest to B.
    2. If A and C are equidistant (for example, the fractional part is exactly .5), the result is the even number.