Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Are these two datetime values equivalent?

From: Kevin Braun <kbraun@-------.--->
To: Michael Kay <mike@--------.--->
Date: 7/30/2009 5:03:00 PM
D.2.2 discusses the lexical space:
/hourFrag/ ::= ([|01|] /digit/ 
<http://www.w3.org/TR/xmlschema11-2/#nt-digit>) | ('|2|' [|0-3|])

On 7/30/2009 12:46 PM, Michael Kay wrote:
>  
>   
>>>    Are these equivalent:
>>>
>>>    2009-07-29T24:00:00-6:00
>>>    2009-07-30T00:00:00-6:00
>>>
>>>       
>
> They are two different lexical representations of the same xs:dateTime
> value. (Just as "1" and "true" are different lexical representations of the
> same boolean). So, once converted into the value space, the values they
> represent are both identical and equal.
>
> More of a problem is that 00:00:00 and 24:00:00 are also different lexical
> representations of the same xs:time value, which means that in XPath you get
> counter-intuitive results for xs:time('24:00:00Z') > xs:time('23:59:59Z').
>
> Kevin Braun> > 24 isn't a valid hour (see part 2, D.2.1)
>
> D.2.1 (of XSD 1.1 part 2) is discussing the value space, not the lexical
> space.
>
> Regards,
>
> Michael Kay
> http://www.saxonica.com/
> http://twitter.com/michaelhkay 
>
>
>   



transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent