Oracle Database Administration I — Question 83
You have been tasked to create a table for a banking application.
One of the columns must meet three requirements:
1. Be stored in a format supporting date arithmetic without using conversion functions
2. Store a loan period of up to 10 years
3. Be used for calculating interest for the number of days the loan remains unpaid
Which data type should you use?
Answer options
- A. INTERVAL YEAR TO MONTH
- B. INTERVAL DAY TO SECOND
- C. TIMESTAMP WITH LOCAL TIMEZONE
- D. TIMESTAMP
- E. TIMESTAMP WITH TIMEZONE
Correct answer: B
Explanation
The correct answer is B, INTERVAL DAY TO SECOND, as it allows for precise date arithmetic and can effectively represent the number of days for calculating interest on overdue loans. The other options either do not support the required arithmetic directly or do not fit the need for a duration suitable for loan periods.