2

OK so I have one parent xsd and one child xsd. For example

Parent.xsd:

        <xs:schema>
        ...
            <xs:element name="a">
                <xs:sequence>
                    <xs:element ref="child:b/>
                </xs:sequence>
            </xs:element>
            <xs:attribute name="c"/>
        ...
        </xs:schema>

Child.xsd

        <xs:schema>
        ...
            <xs:element name="b" >
                <xs:simpleContent>
                    <xs:extension base="..." >
                        <xs:attribute ref="parent:c" />
                    </xs:extension>
                </xs:simpleContent>
            </xs:element>
            ...
            </xs:schema>

Let's assume the schemas are both OK and there are no problems. Of course parent.xsd imports child.xsd with namespace child.

The problem is when I try to import parent.xsd inside child.xsd..it causes some sort of an infinite loops of imports and it is forbidden and doesn't work..

Can't find a proper solution so far..

kitsuneFox
  • 1,243
  • 3
  • 18
  • 31
  • It's permitted (and quite normal) for a.xsd to import b.xsd while b.xsd imports a.xsd. Please tell us exactly what you did (including what XSD processor you were using) and exactly how it failed, and then perhaps we can help you. – Michael Kay Nov 13 '17 at 14:35

0 Answers0