DB2 - Problem description
| Problem IC62754 | Status: Closed |
SQL16163N RECEIVED DURING SCHEMA REGISTRATION WITH SAME ELEMENT NAMES IN DIFFERENT COMPLEXTYPES | |
| product: | |
DB2 FOR LUW / DB2FORLUW / 970 - DB2 | |
| Problem description: | |
Completing a schema registration fails with SQL16163N even
though duplicate elements names in different complex types is
supported.
For example in the following schemas (foo1.xsd, foo2.xsd and
bar1.xsd), an ellement named "childElement" exists in both
"complexType1" and "complexType2". Schema registration should
complete successfully, however, registration fails with the
following error if foo1.xsd or foo2.xsd are the primary
document.
SQL16163N XML document contains a duplicate element
declarationfor "childElement". SQLSTATE=2200M
foo1.xsd
-----------
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://example.org/common">
<xsd:import namespace="http://example.org/order"/>
<xsd:include schemaLocation="foo2.xsd"/>
</xsd:schema>
foo2.xsd
----------
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:common="http://example.org/common"
targetNamespace="http://example.org/common">
<xsd:complexType name="complexType1">
<xsd:sequence>
<xsd:element name="childElement" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="complexType2">
<xsd:sequence>
<xsd:element name="childElement" type="xsd:integer"/>
</xsd:sequence>
</xsd:complexType>
</xsd:schema>
bar1.xsd
-----------
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:common="http://example.org/common"
targetNamespace="http://example.org/order">
<xsd:import namespace="http://example.org/common"/>
<xsd:complexType name="complexType3">
<xsd:sequence>
<xsd:element name="element1" type="common:complexType1"/>
<xsd:element name="element2" type="common:complexType2"/>
</xsd:sequence>
</xsd:complexType>
</xsd:schema> | |
| Problem Summary: | |
**************************************************************** * USERS AFFECTED: * * ALL * **************************************************************** * PROBLEM DESCRIPTION: * * Completing a schema registration fails with SQL16163N even * * though duplicate elements names in different complex types * * is * * supported. * **************************************************************** * RECOMMENDATION: * * Upgrade to V9.7 Fix Pak 1 * **************************************************************** | |
| Local Fix: | |
Try using a different schema as the primary schema. For the example above, schema registration completes successfully when bar1.xsd is used as the primary schema. | |
| available fix packs: | |
DB2 Version 9.7 Fix Pack 1 for Linux, UNIX, and Windows | |
| Solution | |
Problem was first fixed in Version 9.7 Fix Pack 1 | |
| Workaround | |
not known / see Local fix | |
| Timestamps | |
Date - problem reported : Date - problem closed : Date - last modified : | 25.08.2009 04.01.2010 04.01.2010 |
| Problem solved at the following versions (IBM BugInfos) | |
9.7., 9.7.FP1 | |
| Problem solved according to the fixlist(s) of the following version(s) | |
| 9.7.0.1 |
|