Scenario: An application requires precise monetary values to be stored in the database. Which data type is most appropriate for this purpose in DB2?
- CHAR
- DECIMAL
- FLOAT
- INTEGER
DECIMAL data type is the most suitable for storing precise monetary values in a DB2 database. DECIMAL provides exact numeric representation without any rounding or approximation issues, making it ideal for financial calculations where precision is crucial.
Loading...
Related Quiz
- Which type of subquery is executed once for each row returned by the outer query?
- Which factor should be carefully considered before implementing denormalization in a database?
- Indexes with INCLUDE columns in DB2 can optimize ________.
- In DB2, what is the purpose of user roles?
- How does DB2 handle XML or JSON validation?