You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by Kiran BV <bv...@hotmail.com> on 2004/06/15 20:29:03 UTC

XSD import problem in xerces

I validated a certain XSD in XMLSpy which xerces says it is invalid. I am 
not sure what the schema specs have to say about this.

The scenario.

    A.xsd(targetNamespace="X")
         1.  includes B.xsd(targetNamespace="X") that imports 
targetNamespace="Y" using M1.xsd
         2.  includes C.xsd(targetNamespace="X") that imports 
targetNamespace="Y" using M2.xsd

M1.xsd and M2.xsd have the same targetNamespace but are potentially define 
different schema components.

Xerces seems to look at the first import of "Y" and use only M1.xsd and 
ignores M2.xsd.
Should it not add M2.xsd components.
So the systemId and the targetNamespace is a combination hint to not parse 
the same file twice.
This is done right for includes but not imports.

Is this a xerces bug??

Thanks in advance for the help.
Kiran

_________________________________________________________________
FREE pop-up blocking with the new MSN Toolbar – get it now! 
http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/


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


Re: XSD import problem in xerces

Posted by Gareth Reakes <ga...@parthenoncomputing.com>.
Hi Kiran,

 	this behaveiour is consistent with the spec (Part 1):

NOTE: The above is carefully worded so that multiple equivalent 
<redefine>ing of the same schema document will not constitute a violation 
of clause 2 of Schema Properties Correct (3.15.6), but applications are 
allowed, indeed encouraged, to avoid <redefine>ing the same schema 
document in the same way more than once to forestall the necessity of 
establishing identity component by component (although this will have to 
be done for the individual redefinitions themselves).

Gareth

--
Gareth Reakes, Managing Director      Parthenon Computing
+44-1865-811184                  http://www.parthcomp.com

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