You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by bu...@apache.org on 2003/05/20 23:57:47 UTC

DO NOT REPLY [Bug 20087] New: - validating parser error cvc-complex-type.2.4.d

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20087>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20087

validating parser error cvc-complex-type.2.4.d

           Summary: validating parser error cvc-complex-type.2.4.d
           Product: Xerces2-J
           Version: 2.4.0
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: Major
          Priority: Other
         Component: SAX
        AssignedTo: xerces-j-dev@xml.apache.org
        ReportedBy: cathy.y.liu@fmr.com
                CC: cathy.y.liu@fmr.com


The new validating parser return error: cvc-complex-type.2.4.d: Invalid content 
starting with element 'Note'. No child element is expected at this point. This 
used to be valid with the older SAX parser.
 
The XML schema definition is:
	<simpleType name="MemoType">
		<restriction base="string">
			<maxLength value="60"/>
		</restriction>
	</simpleType>
	<!-- Name types are obtained via RetrieveList -->
	<simpleType name="NameType">
		<restriction base="string">
			<enumeration value="FAIL APPR"/>
			<enumeration value="FAIL QC"/>
			<enumeration value="IMAGE RJCT"/>
			<enumeration value="RESOLUTION"/>
		</restriction>
	</simpleType>
	<simpleType name="NoteType">
		<restriction base="string">
			<maxLength value="7500"/>
		</restriction>
	</simpleType>
	<complexType name="ResolutionNoteType">
		<sequence>
			<element name="ControlNo" minOccurs="0">
				<simpleType>
					<restriction base="string">
						<maxLength value="14"/>
					</restriction>
				</simpleType>
			</element>
			<choice>
				<sequence>
					<element name="Memo" type="t:MemoType"/>
					<element name="Name" type="t:NameType" 
minOccurs="0"/>
				</sequence>
				<sequence>
					<element name="Name" type="t:NameType" 
minOccurs="0"/>
					<element name="Note" type="t:NoteType"/>
				</sequence>
				<sequence>
					<element name="Memo" type="t:MemoType"/>
					<element name="Name" type="t:NameType" 
minOccurs="0"/>
					<element name="Note" type="t:NoteType"/>
				</sequence>
			</choice>
		</sequence>
	</complexType>

The xml is:
	<ResolutionNote>
		<ControlNo>1Control#Added</ControlNo>
		<Memo>This is the Memo text that was added to a workitem Note 
Memo</Memo>
		<Name>RESOLUTION</Name>
		<Note></Note>
	</ResolutionNote>

This used to be valid with the older SAX parser.  The XmlSpy also indicates the 
xml is valid when validating against the schema.

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-dev-help@xml.apache.org