Was this helpful?
Money Data Type
The money data type is an abstract data type. Money values are stored significant to two decimal places. Money values are rounded to dollars and cents on input and output, and arithmetic operations on the money data type retain two-decimal-place precision.
The range of money values is:
$-999,999,999,999.99 to $999,999,999,999.99
You can specify a money value as either:
A character string literal
The format for character string input of a money value is "$sdddddddddddd.dd". The dollar sign is optional and the algebraic sign (s) defaults to + if not specified. You do not need to specify a cents value of zero (.00).
A number
Any valid integer or floating point number is acceptable. The DBMS Server converts the number to the money data type automatically.
On output, money values are displayed as strings of 20 characters with a default precision of two decimal places. The display format is:
Is the default currency symbol
Is a digit from 0 to 9
The following settings affect the display of money data. For details, see the System Administrator Guide.
Specifies the character displayed as the currency symbol. The default currency sign is the dollar sign ($).
Specifies the number of digits displayed after the decimal point. Valid settings are 0, 1, and 2.
Specifies the character displayed as the decimal point. The default decimal point character is a period (.).
Last modified date: 06/10/2024