ISO 8601:2000(E)
20
© ISO 2000 ­ All rights reserved
5.5 Time-intervals
5.5.1 Means of specifying time-intervals
A time-interval shall be expressed in one of the following ways:
a) by a start and an end;
b) by a duration not associated with any start or end;
c) by a start and a duration;
d) by a duration and an end.
5.5.2 Separators and designators
A time interval is expressed according to the following rules:
a) a solidus [/] shall be used to separate the two components in each of 5.5.1 a), c) and d).
b) for 5.5.1 b), c) and d) the designator [P] shall precede, without spaces, the representation of the duration.
c) other designators (and the hyphen when used to indicate omitted components) shall be used as shown in
5.5.4 and 5.5.5 below.
NOTE
In certain application areas a double hyphen is used as a separator instead of a solidus.
5.5.3 Representation of duration
5.5.3.1
Format with time-unit designators
In expressions of time-interval or recurring time-interval duration can be represented by a data element using time unit
designators. The number of years shall be followed by the designator [Y], the number of months by [M], the number of
weeks by [W], and the number of days by [D]. The part including time components shall be preceded by the
designator [T]; the number of hours shall be followed by [H], the number of minutes by [M] and the number of
seconds by [S]. In the examples [n] represents one or more digits, constituting a positive integer or zero.
In basic and extended format the complete representation for duration shall be nYnMnDTnHnMnS or nW.
For reduced precision, decimal or truncated representations of this format the following rules apply.
a) If necessary for a particular application the lowest order components may be omitted to represent duration with
reduced precision.
b) If necessary for a particular application the lowest order component may have a decimal fraction. The decimal
fraction shall be divided from the integer part by the decimal sign specified in ISO 31-0: i.e. the comma [,] or
full stop [.]. Of these, the comma is the preferred sign. The decimal fraction shall at least have one digit. If the
magnitude of the number is less than unity, the decimal sign shall be preceded by a zero (see ISO 31-0).
c) If the number of years, months, days, hours, minutes or seconds in any of these expressions equals zero, the
number and the corresponding designator may be absent; however, at least one number and its designator
shall be present. Note that the removal of leading non-zero components is not allowed.
d) The designator T shall be absent if all of the time components are absent.