Troubleshooting
Problem
XML attributes may be displayed/created in a different order when using a Native XML Schema in an ITX map when compared to the order in the original XML Schema.
Symptom
XML attributes are in a different order when using Native XML Schema than in the XML Schema.
Cause
According to the XML specification, the order of attribute specifications in a start-tag or empty-element tag is not significant. Please see the following link.
https://www.w3.org/TR/REC-xml/#sec-starttags
Attributes can appear in any order.
Native schema displays the attributes in alphabetical order.
Environment
Using Native XML Schema which uses the Xerces parser and the XML schema for a Typetree.
Diagnosing The Problem
Looking at the fields in a card of an IBM Transformation Extender (ITX) Map the sequence of the XML attributes are in a different order than they are in the actual XML Schema.
Resolving The Problem
You could use the ITX XML Schema importer instead of using the Native XML Schema. The ITX XML Schema importer will create an editable Typetree.
If the data order is important to the application processing the XML, you should use elements in a sequence.
Was this topic helpful?
Document Information
Modified date:
16 June 2018
UID
swg22013997