Operator Type:
Operator Scope of Action:
Operator Purpose:
Operator First Added:
Operator Altered:
Property [other Property type actions]
Item [operators of similar scope]
Date-time [other Date-time operators]
Baseline
$MyInterval.day
Returns the Interval expressed as a Number of whole days. Thus, if $MyInterval is 1day 12 hours 30 minutes then:
$MyNumber = $MyInterval.day;
returns 1
Older behaviour
Prior to v8.0.4 it returned the entire interval expressed as days. Thus, 1 day 12 hours and 30 minutes returned 1.52083.
If $MyInterval is 1day 12 hours 30 minutes then:
$MyNumber = $MyInterval.day;
returns 1.52083
To get an integer value, i.e. whole days, use either Number.precision() or floor(), thus:
$MyNumber = $MyInterval.day.precision(0);
returns 1
$MyNumber = floor($MyInterval.day);
returns 1