cancel
Showing results for 
Search instead for 
Did you mean: 

Duplicate XSD Schema includes, are they valid?

Former Member
0 Kudos

I have a rather complex XSD schema which has broken out reusable components in several

library schemas which are leveraged via an include statement.

I have the following scenario.

MasterSchemaA.xsd

LibSchemaB.xsd

LibSchemaC.xsd

LibSchemaC

<xs:include: schemaLocation="LibSchemaB.xsd"/>

MasterSchemaA

<xs:include: schemaLocation="LibSchemaB.xsd"/>

<xs:include: schemaLocation="LibSchemaC.xsd"/>

If a complex element in LibSchemaC references one in LibSchemaB, then in MasterSchemaA,

it references both the LibSchemaC new complex element prime, built on a base complex element in LibSchemaB,

and the base complex element in LibSchemaB, will this schema be valid for the SAP XSD Schema importer/xml validator?

If not, is it considered syntactically correct or within the XSD schema standard?

Any input would be much appreciated.

Regards,

Mike

Accepted Solutions (0)

Answers (1)

Answers (1)

prateek
Active Contributor
0 Kudos

You may use xs:import statement in the parent xsd and import all of them. A lengthier way is also explained here.

/people/james.guanzon/blog/2006/02/22/how-to-support-industry-standards-in-xi-part-i-of-iii--interfaces

Regards,

Prateek

Former Member
0 Kudos

Thanks for providing the link, it's helpful for understanding the mechanics of how to import an XML Schema, however, this doesn't answer my question.

I'm trying to understand how SAP will parse/interpret a complex schema which makes references to several other schemas which in themselves make reference to, include, other schemas which may already be included in the includee schema.

If SAP comes across a complex element that has already been defined in a previous include statement, does it simply throw out the newly referenced include or does it manage to track it. My concern are complex elements built on complex elements referenced in the includes.

Regards,

Mike