MONEY(p,s)

The MONEY data type is provided to store currency amounts with exact decimal storage.

Syntax

MONEY [ (precision[,scale]) ]
  1. precision defines the number of significant digits (limit is 32, default is 16).
  2. scale defines the number of digits to the right of the decimal point.
  3. When no scale is specified, it defaults to 2.

Usage

The MONEY data type is provided to store currency amounts. Its behavior is similar to the DECIMAL data type, with some important differences:

A MONEY variable is displayed with the currency symbol defined in the DBMONEY environment variable.

You cannot define floating-point numbers with MONEY: If you do not specific the scale in the data type declaration, it defaults to 2. If no precision / scale parameters are specified, MONEY is interpreted as a DECIMAL(16,2).