Hi Axis Members ,
I have one issue with XSDs along with Axis2
We have two XSDs (SchemaOne.xsd and SchemaTwo.xsd) with no namespaces
defined.
Both XSDs contains single element of same name and type
We have one WSDL which imports it with two different namespaces as
given below to avoid name collision
<xsd:schema
xmlns:tns="http://xml.com/SchemaOne"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://xml.com/SchemaOne"
elementFormDefault="qualified"
attributeFormDefault="unqualified">
<xsd:include schemaLocation="SchemaOne.xsd" />
</xsd:schema>
<xsd:schema
xmlns:tns="http://xml.com/SchemaTwo"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://xml.com/SchemaTwo"
elementFormDefault="qualified"
attributeFormDefault="unqualified">
<xsd:include schemaLocation="SchemaTwo.xsd" />
</xsd:schema>
When I validate WSDL with Altova XML Spy it is showing
"Invalid XML schema: ''UnsuspendRequest' is already declared in schema document
'C:\SchemaOne.xsd'."
How can I get rid of this error?
Attached WSDL and XSDs.
Thanks in advance,
Appasamy AT
<mailto:[email protected]>
error4.wsdl
Description: error4.wsdl
<?xml version="1.0" encoding="UTF-8"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified"> <xs:element name="UnsuspendRequest" type="xs:string"/> </xs:schema>
<?xml version="1.0" encoding="UTF-8"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified"> <xs:element name="UnsuspendRequest" type="xs:string"/> </xs:schema>
