Sam,
Thanks for posting!
Yes, I made sure to read the documentation very closely but it didn't seem to shed any light on this particular error - other than "SimpleTypes must come after their base types in the schema body."
I searched through the module source and found where the error was being generated:
_err("Found <simpleType> illegally combined with complexType>.") if $mother->{is_complex};
By "illegally combined" does the error mean simpleType cannot be a child (or parent) of complexType?
I hope the following .xsd snippet will be helpful as it seem s exemplary of the file as a whole.
SAMPLE XSD MARKUP
<xsd:element name="Phone" type="PhoneType" minOccurs="0"/>
<xsd:element name="Fax" minOccurs="0">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="F_AreaCode" nillable="1">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:length value="3"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="F_Prefix" nillable="1">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:length value="3"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="F_Suffix" nillable="1">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:length value="4"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
END SAMPLE XSD
Any help is appreciated.
j
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.
|