For discussion on next WG call.

Section 13.11.1. of the DFDL 1.0 spec defines the formatting symbols that can be used for calendar patterns. In addition to the supported ICU symbols, it also permits some extra symbols (I and T) that are used as a shorthand for ISO8601 format date/times. The following is quoted from the spec.

Currently

Symbol   Meaning                                 Presentation                Example
I        ISO8601 Date/Time                 (Text)                 2006-10-07T12:06:56.568+01:00
IU        ISO8601 Date/Time                 (Text)                 2006-10-07T12:06:56.568Z
        with output "Z" if the
        time zone is +00:00)
T        ISO8601 Time                 (Text)                12:06:56.568+01:00
        (up to HH:mm:ss.SSSZZZ)
TU        ISO8601 Time                 (Text)                12:06:56.568Z
        (similar to T, but a time zone
        of +00:00 is replaced with 'Z')

The 'I' and 'T' pattern characters should be used on their own to format dates and times which match the following subset of the ISO8601 standard.

·        The restricted profile as proposed by the W3C at http://www.w3.org/TR/NOTE-datetime

·        Truncated representations of calendar dates, as specified in section 5.2.1.3 of ISO8601:2000

o        Basic format (subsections c, e, and f)

o        Extended format (subsections a, b, and d)


An analysis shows that this definition of I and T is both incomplete and overly complex.  



Proposal

Here is what is proposed to correct this. Note the T symbol is dropped. It was introduced to allow xs:dateTime to expect just a time, but that is not necessary (it was copied from IBM MRM). I've stated any alternatives that we can consider at the end.


Symbol   Meaning                                 Presentation                Example
I        ISO8601 Date/Time                 (Text)                 2006-10-07T12:06:56.568+01:00
IU        ISO8601 Date/Time                 (Text)                 2006-10-07T12:06:56.568Z
        with output "Z" if the
        time zone is +00:00)

The 'I' symbol must not be used with any other symbol other than the 'escape for text' symbol. It represents calendar formats that match those defined in the restricted profile of the ISO8601 standard proposed by the W3C at http://www.w3.org/TR/NOTE-datetime.The formats are referred to as 'granularities'.


Alternatives:

As above but don't support the first two granularities ('Year', 'Year and month') on the grounds that they are really matching xs:gYear and xs:gYearMonth.


Regards

Steve Hanson
Architect, Data Format Description Language (DFDL)
Co-Chair,
OGF DFDL Working Group
IBM SWG, Hursley, UK

smh@uk.ibm.com
tel:+44-1962-815848







Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number 741598.
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU