txttransform utility

This utility transforms data between a character-delimited variable format and an XML format.

Before you run this utility configure the loading utilities.

File names specified as parameters for this utility can be preceded by relative or absolute paths. Relative paths must be relative to the directory from which you run the txttransform utility.

This utility produces the following log file:

  • DB2WC_installdir/logs/txttransfrom.db2.log
  • OracleWC_installdir/logs/txttransform.oracle.log
  • WebSphere Commerce DeveloperWCDE_installdir/logs/txttransform.log

SolarisLinuxAIX Run this utility as the non-root WebSphere Commerce user ID. Do not run this command as root.

txttransform utility syntax diagram. See the list that is called Parameter values for the applicable parameters.

Utility command

The txttransform utility has the following file name:

  • For IBM i OS operating systemSolarisLinuxAIX txttransform.sh
  • Windows txttransform.cmd
  • WebSphere Commerce Developer txttransform.bat

Parameter values

The following required values are specified and separated by commas in a parameter file (parameter.txt):

Input file
Name of the character-delimited variable format file to be transformed.
Schema file
Name of the XML schema file to be used in the transformation.
Output file
Name for the output XML file in which the transformed data is stored.
Transformation method
Method to be used in adding the data to the output file. The following methods are valid:
Create
Create a new XML file from the text file.
Append
Append new XML data to an existing XML file.
Encoding
The character encoding scheme of the input file. Any character encoding scheme that is supported by Java can be specified. This parameter is optional. The default character encoding scheme is UTF-8, and is used if a value for this parameter is not specified.

All of these parameters are required, except for Encoding parameter, which is optional. The parameters must be specified in the order listed. If the order of parameters in the parameter file does not match the order of parameters that are listed, the txttransform utility fails.

For example, to create an XML file (catalog.xml) from a UTF-8 encoded comma-separated value (CSV) file (sample.csv) by using the schema defined in an XML schema file (sample_schema.xml), the parameter file for the txttransform utility contains the following line of text:
sample.csv,sample_schema.xml,catalog.xml,Create,UTF8