[osis-core] OSIS_0105:17 <date> from xs:dateTime?
Todd Tillinghast
osis-core@bibletechnologieswg.org
Tue, 9 Apr 2002 14:47:19 -0500
Are you saying that this detail is not found in print publications or that
it is not enforced by print publications?
If you are saying that it is not enforced by print publications then the
thought to consider is that XML documents are read by computers (and
sometimes by humans) and computers are not good a guessing what free text
means.
If you are saying that this detail is not found in print publications (and
is not important) then lets get rid of it OR lets make it a useful value
that is fully validated.
Elements that are more strictly validated are more useful. In this case the
value should ALWAYS be a date of some kind. And there is well established
standard for how to encode them. When an element/attribute is not just
"free text" and is forced to be in a specified format or an option from a
set enumerated values, then users can reliability use the contents of the
element (assuming the document has been validated against the indicated
schema) without having to code for invalid data.
With <date> as xs:string the following are possible:
<date>The year of our Lord 1990</date>
<date>XXIV</date> (Date in Roman numerals, a poor example, but you should
get the idea.)
<date>Jan-12-2002</date>
<date>99</date>
<date>2002AD</date>
<date>2002-A.D.</date>
<date>200204</date>
<date>0204</date>
<date>200402</date>
What is meant by theses cases is somewhat clear in come cases if read by a
human but is totally useless to a computer. Why not use the standard that
exists when there is not harm in requiring proper date encoding. Those who
don't know how to encode a date should study up on XML and then get back to
encoding. Also an example document will make the format clear to any
encoder regardless of training.
Todd
----- Original Message -----
From: "Patrick Durusau" <pdurusau@emory.edu>
To: <osis-core@bibletechnologieswg.org>
Sent: Monday, April 08, 2002 8:48 AM
Subject: Re: [osis-core] OSIS_0105:17 <date> from xs:dateTime?
> Todd,
>
> Todd Tillinghast wrote:
>
> >I was thinking that the hh:mm:ss part is optional (defaulted to
> >midnight, if left blank) in xs:dateTime. This is not the case. However
> >we could do the following. That would have the same impact.
> >
> >This would cause no impact on those who simple want to provide a date
> >only but allows for a date/time for interested parties.
> >
> >See the following schema fragment and xml document fragment:
> >SCHEMA:
> ><xs:element name="date" type="DateOrDateTime"/>
> ><xs:simpleType name="DateOrDateTime">
> > <xs:union memberTypes="xs:date xs:dateTime"/>
> ></xs:simpleType>
> >
> >DOCUMENT: (BOTH are valid!!!!!)
> ><date>2001-04-07T13:20:33</date>
> ><date>2001-04-07</date>
> >
> Yes, if we want to compell year-month-day on the date element. I guess I
> am missing why we would be enforcing detail that is not commonly found
> in print publications? Can be done, my question is should it be done?
>
> Patrick
>
>
> >
> >Looks like a beautiful thing to me!
> >
> >Todd
> >
> >>-----Original Message-----
> >>From: owner-osis-core@bibletechnologieswg.org [mailto:owner-osis-
> >>core@bibletechnologieswg.org] On Behalf Of Patrick Durusau
> >>Sent: Saturday, April 06, 2002 12:40 PM
> >>To: osis-core@bibletechnologieswg.org
> >>Subject: [osis-core] OSIS_0105:17 <date> from xs:dateTime?
> >>
> >>Todd,
> >>
> >>Todd Tillinghast wrote:
> >>
> >>>9) <date> should be derived from xs:dateTime! (Not from xs:date to
> >>>
> >allow
> >
> >>>for time to be used by electronic publishers.)
> >>>
> >>Not sure that the basic release should require the hh:mm:ss parts of
> >>dateTime. More appropriate for publisher (electronic publisher
> >>
> >module?)?
> >
> >>Patrick
> >>
> >>--
> >>Patrick Durusau
> >>Director of Research and Development
> >>Society of Biblical Literature
> >>pdurusau@emory.edu
> >>
> >>
> >
>
> --
> Patrick Durusau
> Director of Research and Development
> Society of Biblical Literature
> pdurusau@emory.edu
>
>
>
>