The invdivdbl() function
The invdivdbl() function divides an interval value by a numeric value.
Syntax
mint invdivdbl(iv, num, ov)
intrvl_t *iv;
double num;
intrvl_t *ov;
- iv
- A pointer to the interval value to be divided.
- num
- A numeric divisor value.
- ov
- A pointer to an interval variable with a valid qualifier, to contain the result of the division.
Usage
The input and output qualifiers must both belong to the same interval class: either the year to month class or the day to fraction(5) class. If the qualifier for ov is different from the qualifier for iv (within the same class), the invdivdbl() function extends the result (as the invextend() function defines).
The invdivdbl() function divides the interval value in iv by num and stores the result in ov.
The value in num can be either a positive or a negative value.
Return values
- 0
- The division was successful.
- <0
- The division failed.
- -1200
- A numeric value is too large (in magnitude).
- -1201
- A numeric value is too small (in magnitude).
- -1202
- The num parameter is zero.
- -1265
- Overflow occurred on an interval operation.
- -1266
- An interval value is incompatible with the operation.
- -1268
- A parameter contains an invalid interval qualifier.