[XMLSCHEMA-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Attribute question

From: Jonny Pony <jonnypony666@hotmail.com>
Date: Thu, 18 Dec 2003 21:53:56 +0000
To: xmlschema-dev@w3.org
Message-ID: <Law14-F70cx4vvsGOke0003139a@hotmail.com>
Attribute question

Hi,

I want for XML-output something like this
...
<Row>
<Entrie type="decimal" digits="3">blabla</Entrie>
<Entrie type="integer" digits="0">blabla</Entrie>
</Row>

My schema:
...
<xs:sequence>
<xs:element name="Entrie" type="xs:string">
<xs:complexType>
<xs:complexContent>
<xs:restriction base="xs:anyType">
<xs:attribute name="type" type="xs:string" use="required"/>
<xs:attribute name="digits" type="xs:integer" use="optional"/>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
</xs:element>
</xs:sequence>

But this "schema code" doesn't function.
When I want to validate my xml against this schema in XMLSpy it says 
"unexpected attributes". Without attributes I can validate it. Strange.
Am I right or XMLSpy?

Thanks
Jonny

_________________________________________________________________
FreeSMS abräumen mit dem MSN Messenger - der Countdown läuft! 
http://messenger-mania.msn.de Jetzt mitmachen und gewinnen!
Received on Friday, 19 December 2003 05:43:11 GMT

Subscribe to the Stylus Scoop newsletter for helpful XML tips and tutorials.
Email
First Name
Last Name
Company

Download Stylus Studio 6 XML Enterprise Edition

Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2007 All Rights Reserved.