- From: Michael Rys <mrys@microsoft.com>
- Date: Sat, 6 Mar 2004 13:44:00 -0800
- To: "Michael Kay" <mhk@mhk.me.uk>, "Henry S. Thompson" <ht@inf.ed.ac.uk>, <public-qt-comments@w3.org>
I don't think that there is a requirement to preserve the value in a pattern compatible way even if we would preserve the type. So I do not think that "Alternative 1" has anything to do with this issue. Best regards Michael > -----Original Message----- > From: public-qt-comments-request@w3.org [mailto:public-qt-comments- > request@w3.org] On Behalf Of Michael Kay > Sent: Saturday, March 06, 2004 1:42 PM > To: 'Henry S. Thompson'; public-qt-comments@w3.org > Subject: RE: Ref XSCH-QL-018: Example of pblm with serialization-based > validation > > > This problem is certainly a known one. But it's not serialization that > causes the problem, it's the fact that the constructs that create nodes on > the result tree (in both XSLT and XQuery) convert values to strings and > discard the type information. (The infamous "Alternative 1".) > > Michael Kay > > # -----Original Message----- > # From: public-qt-comments-request@w3.org [mailto:public-qt-comments- > # request@w3.org] On Behalf Of Henry S. Thompson > # Sent: 06 March 2004 15:11 > # To: public-qt-comments@w3.org > # Subject: Ref XSCH-QL-018: Example of pblm with serialization-based > # validation > # > # > # Consider the following schema document and instance: > # > # <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> > # <xs:element name="root"> > # <xs:simpleType> > # <xs:restriction base="xs:decimal"> > # <xs:annotation> > # <xs:documentation>Always two signif. digits</xs:documentation> > # </xs:annotation> > # <xs:pattern value=".*\..."/> > # </xs:restriction> > # </xs:simpleType> > # </xs:element> > # </xs:schema> > # > # <root>3.00</root> > # > # The instance is valid per the schema corresponding to the schema > document. > # > # A query which attempted to construct an element including this one > # would however fail, as I read the spec., because the serialization > # would include <root>3.0</root>, which is invalid per the type. > # > # ht > # -- > # Henry S. Thompson, HCRC Language Technology Group, University of > # Edinburgh > # Half-time member of W3C Team > # 2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440 > # Fax: (44) 131 650-4587, e-mail: ht@inf.ed.ac.uk > # URL: http://www.ltg.ed.ac.uk/~ht/ > # [mail really from me _always_ has this .sig -- mail without it is forged > # spam] >
Received on Saturday, 6 March 2004 16:44:31 UTC