W3C home > Mailing lists > Public > public-qt-comments@w3.org > June 2006

[Bug 3369] [F+O] Operations on xs:duration

From: <bugzilla@wiggum.w3.org>
Date: Mon, 19 Jun 2006 19:10:46 +0000
CC:
To: public-qt-comments@w3.org
Message-Id: <E1FsP94-0007qe-AY@wiggum.w3.org>

http://www.w3.org/Bugs/Public/show_bug.cgi?id=3369

           Summary: [F+O] Operations on xs:duration
           Product: XPath / XQuery / XSLT
           Version: Candidate Recommendation
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Functions and Operators
        AssignedTo: ashok.malhotra@oracle.com
        ReportedBy: mike@saxonica.com
         QAContact: public-qt-comments@w3.org


Section 10.1 of F+O wrongly states:

"Note that only equality is defined on xs:duration values."

This is no longer true: for example, we define casting operations and component
extraction on durations. It might be better to say "Note that no ordering
relation is defined on xs:duration values. Two xs:duration values may however
be compared for equality."

The spec doesn't seem to say how component extraction on durations works. For
example, given a duration of 90S, what does seconds-from-duration() return?
Test case fn-seconds-from-duration-20 assumes 30.0, which is reasonable, but I
can't find anything to back this up, and it runs contrary to the statement in
XML Schema that a duration is a 6-tuple. I suggest we add a statement that
days|hours|minutes|seconds-from-duration($d) returns the same as
days|hours|minutes|seconds-from-duration(xs:dayTimeDuration($d)), and
year|month-from-duration($d) returns the same as
year|month-from-duration(xs:yearMonthDuration($d))
Received on Monday, 19 June 2006 19:10:49 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:57:12 UTC