Message: A new issue has been created in JIRA.
--------------------------------------------------------------------- View the issue: http://issues.apache.org/jira/browse/XERCESC-1209 Here is an overview of the issue: --------------------------------------------------------------------- Key: XERCESC-1209 Summary: Problem with id usage across schema documents Type: Bug Status: Unassigned Priority: Blocker Project: Xerces-C++ Components: Validating Parser (Schema) (Xerces 1.5 or up only) Versions: 2.4.0 Assignee: Reporter: Kiran Created: Wed, 12 May 2004 1:37 PM Updated: Wed, 12 May 2004 1:37 PM Environment: Win 2K Description: I verified this with the XercesJ parser and it does NOT complain if id are unique across schema files. Why is ID handling different for the C++ and Java version. If we look at this from the XML angle, the ID should be unique only with the same document not across documents. So why is XercesC giving an error. Here is the response from xml schema dev mailing list There's no conflict. The xsd:include is not the same as an XInclude include. xsd:include 'includes' the schema components that belong to the *parsed* included schema document. It doesn't 'include' the xml representation of the included schema document, so the DTD for schemas is not applicable. As far as I can tell, the id attribute doesn't constrain the schema components (only their XML representations). xan --------------------------------------------------------------------------------------------------------------- For eg. if I have schema A.xsd <xsd:schema id="ABC"> <xsd:include schemaLocation="B.xsd"> <xsd:element name="x" type="xsd:string"> </xsd:schema> schema B.xsd <xsd:schema id="ABC"> //HERE ABC value is repeated as a id </xsd:schema> If we look A.xsd as standalone XML having a id attribute it is unique. However if I parse A.xsd, I get an error in B.xsd saying the id attribute is duplicated. Strangely the schema spec is silent on this. Looks like the xerces schema parser checks ids in totality including 'includes' and 'imports'. What is the correct behaviour. Should this resort to a single document with an id like XML or consider the include and import set for id uniqueness. --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]