Multiple choice technology databases

Given the following scenario: Table TABLE1 needs to hold specific numeric values up to 9999999.999 in column COL1. Once TABLE1 is populated, arithmetic operations will be performed on data stored in col-umn COL1. Which of the following would be the most appropriate DB2 data type to use for column COL1?

  1. INTEGER

  2. REAL

  3. NUMERIC (7,3)

  4. DECIMAL(10,3)

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

To store values up to 9999999.999 (7 digits before decimal, 3 after), DECIMAL(10,3) provides the needed precision with 10 total digits and 3 decimal places. INTEGER has no decimals, REAL is approximate floating-point, and NUMERIC(7,3) only allows 4 digits before the decimal (9999.999 max), insufficient for the required range. Options A, B, and C cannot represent the full range of required values.