Restrictions on XML conversions
-
DataMagic uses libxml2 (http://www.xmlsoft.org/) to read input XML files. libxml2 conforms to the XML 1.0 specifications. If you read any input XML files that do not conform to the XML 1.0 specifications, errors might occur.
-
If the data is output to an XML file, Append cannot be specified.
-
If the elements of the XML file comprise only blank characters (0x0A, 0x0D, 0x09 and 0x20), these elements are considered to be null.
-
When the elements of the XML file are defined as numeric data, if you try to input or output any string other than numeric strings or strings that can be converted to numerics, a conversion error occurs.
-
When the output XML information is XML Schema and XML Schema instance attributes is set to Output in the Output Settings screen of the Data Processing Settings screen, if the target namespace has been specified, the URI of the target namespace is output to the output XML as the default namespace. The XML Schema instance attribute (schemaLocation or noNamespaceSchemaLocation attribute) is output only if Schema location is specified in the Output Settings screen.
-
External characters are supported if the character encoding of the input XML file is UTF-8 or UTF-16. For other character encodings, external characters are not supported. If an input XML file in a character encoding other than UTF-8 and UTF-16 contains external characters, a conversion error occurs.
-
If the XML record unit is set to "2" or "3" in the XML output, attributes defined at levels higher than the specified repeating levels are not output, even if they are mapped. To output attributes to higher levels, set the XML record unit to "Custom".
-
If you have mapped parent elements to each other in both input and output XML files, you cannot set the child item information (the Handling of trailing spaces after character data and Handling of leading zeroes in numeric data settings). For these settings, the setting for the output file is used. Additionally, user exit programs cannot be configured in this case.
-
The input XML file and the input schema file are not checked for validity.
-
The output XML file is not guaranteed to be valid for the output schema file.
-
The output XML file is not guaranteed to be well formed. For example, an XML file whose element name begins with a numeric is output as is.
-
You can import a DTD file of an external subset having descriptions only permitted to external DTDs as XML information, and then import the information to the XML file as an internal subset, and then output the information. In this case, the information is output to the output XML file as is. Therefore, the XML file is not well formed.
-
If the input is an XML file, the numeric operation expression cannot include "$INUM".
-
When the input is an XML file, if you use an API with specified field numbers in a user exit program, an error occurs.
-
If normal text and CDATA sections coexist in the text part of the input XML file, the value that is applied is the one that occurs first. All successive values are ignored. In the example illustrated below, "aaa" is applied for the value of the child element.
Figure 4.90 Coexistence of text and CDATA section
-
Only one set of XML information can be associated with an input XML file. Therefore, any input XML file referencing multiple schema files is not supported.
-
If you set the XML record unit to "1" or "Element" for input XML files, the memory usage depends on the size of the input file.
-
If you set the XML record unit to "Custom" for output XML files, the memory usage depends on the size of the input file.
-
The encoding attribute in the XML header that is supported for input XML files can be Shift JIS, EUC-JP, UTF-8, or UTF-16.
-
If you create layout information from an XML schema that includes a data-type facet, the settings of the facet are not imported.
-
If there are multiple elements with the same name at the same level of the XML information, conversions might not be performed correctly.
- Conditions of occurrence
-
There are multiple elements with the same name in the same level of the XML
You map the second or successive elements that have the same name within the same level
- Actions
-
- When mapping is specified to the input:
-
(1) Conversions are performed correctly, but the second or successive data having the same name within the same level is not output.
- When mapping is specified to the output:
-
(1) Conversions are performed correctly, but the second or successive data having the same name within the same level is not output.
(2) Mapping errors might occur.
-
You must specify "element" for the first element in the schema file.
-
The values of "maxOccurs" and "minOccurs" for contents model are ignored when conversions are performed. Conversions are performed for the same number of times as items occurred. Additionally, these values are also ignored in the trees in the Set Mapping Information screen. Therefore, the number of occurrences of repetitive items might differ from the specified value.
-
If the output XML information is specified as the XML information ID that was created by importing the DTD, no prefix can be added.
-
Results of conversions might differ depending on the "maxOccurs" setting, which indicates the number of occurrences of elements in the XML schema.
If "maxOccurs" is set to 2 or more for an element, the repetition setting for the element takes precedence over the setting of the record unit.
-
On a mapping screen for which XML information is specified for the output and the record unit is set to Custom, if the setting of the starting point of repetition is in one of the following states, XML data might not be output correctly.
-
No mapping is performed for the element specified as the starting point of repetition and its descendant elements.
-
Multiple conditions are set, and the elements specified as a starting point of repetition are not set sequentially from the XML parent hierarchy in the order of the conditions.
-
-
A namespace cannot be specified in an XML schema attribute.
-
Use input XML files that are 2GB or smaller. If you attempt to process data larger than this size, an input error may occur.
-
If all the conditions below are met, the output results may be invalid. In this case, divide the data processing information into multiple parts and execute data processing so as not to meet any of the following conditions:
-
Input file is in XML format.
-
Multiple extraction conditions are specified.
-
In mapping, elements that are designated as output fields are in a model/sub-model that is different from the model of the element specified for the extraction condition.
The following are examples of settings that result in invalid output:
Screen 4.51 Example settings: Multiple extraction conditions (element "a" and "d") are specified in Extract Key Settings
Screen 4.52 Example settings: In extraction condition 1 (element "a") in Set Mapping Information, the elements (element "c" and "d") in the model of extraction condition 2 (element "d") and the elements (element "e" and "f") in its sub-model are specified as output fields
Screen 4.53 Example settings: In extraction condition 2 (element "d") in Set Mapping Information, the elements (element "a" and "b") in the model of extraction condition 1 (element "a") are specified as output fields
-