Table of Contents

Search

  1. Preface
  2. XML Concepts
  3. Using XML with PowerCenter
  4. Working with XML Sources
  5. Using the XML Editor
  6. Working with XML Targets
  7. XML Source Qualifier Transformation
  8. Midstream XML Transformations
  9. Appendix A: XML Datatype Reference
  10. Appendix B: XPath Query Functions Reference

XML Guide

XML Guide

Generating Pass-Through Ports

Generating Pass-Through Ports

Pass-through ports are columns that pass non-XML data through a midstream XML transformation. For example, you can pass message IDs with XML for MQSeries sources and targets. Use the message ID to correlate input and output messages for requests and replies.
When you define a pass-through port in the midstream transformation, you add the pass-through port to either the DataInput group in the XML Parser transformation or the DataOutput group in the XML Generator transformation.
Once you generate the port, you use the XML Editor to add a corresponding reference port to another view in the XML definition. In the XML Parser transformation, the pass-through port is an input port, and the corresponding reference port is an output port. In the XML Generator transformation, the pass-through port is an output port and the associated reference port is an input port.
To create a pass-through port in a midstream XML transformation:
  1. Open the transformation in the Transformation Developer or Mapping Designer.
  2. Double-click the transformation to open Edit Transformations.
  3. Click the Midstream XML Generator or Midstream XML Parser tab.
    The DataInput or DataOutput port appears, depending on the transformation type.
  4. Click the Add button to add an output port for the pass-through.
    A default field appears in the Field Name column.
  5. Modify the field name. You can also modify type, precision, and scale depending on the file you used to create the definition.
  6. Click XML Editor to open the XML definition for the transformation.
    The XML views in the definition appear in the workspace.
  7. Right-click the top of a view to add the reference port.
  8. Select Add a Reference Port.
    The Reference Port dialog box opens.
    The dialog box lists the pass-through ports you added in the transformation.
  9. Select the pass-through port that will correspond to the new reference port in the view and click OK.
    The corresponding output reference port appears in the view. You can rename the port to a meaningful name in the Columns window.
  10. Click Apply Changes and exit the XML Editor.
  11. Click OK in the transformation.
Non-XML data comes through the input port called Pass_thru_field and passes through the corresponding COL_0 reference output port.

0 COMMENTS

We’d like to hear from you!