Implementing XML Mapper

This section provides an overview of XML Mapper and discusses how to set it up.

Page Name

Definition Name

Usage

Defining Maps Page

SAC_MAP_DEFN

Use to define the type of transformation and to which message, records, and fields it applies.

Map Detail Page

SAC_MAP_DEFN_DTL

Use to specify the map type detail.

Define Map Sets Page

SAC_MAPSETDEFN

Use to group maps together, order them, and specify in which directions they apply.

Define Node Associations Page

SAC_NODE_ASSOC

Use to associate a source node and a target node with a map set. All maps in an associated map set will then execute using the node association. Before defining a node association, set up an Integration Broker service operation routings for your nodes.

XML Mapper enables you to map values between your database and an external trading partner database. For example, if you are integrating to a computer hardware supplier, if you use a field called business unit, and the supplier uses a field called BU, you can set up a mapping relationship where your outbound purchase order XML transaction automatically converts data in business unit fields to BU fields.

Before you being using XML Mapper, you must:

  • Activate service operations set up in Integration Broker.

  • Set up an integration broker relationship including transaction modifiers for the node associations.

PeopleTools: Integration Broker

Use the Define Map page (SAC_MAP_DEFN) to use to define the type of transformation and to which message, records, and fields it applies.

Navigation:

SCM Integrations > XML Mapper > Define Maps

This example illustrates the fields and controls on the Define Maps. You can find definitions for the fields and controls later on this page.

Define Maps

Field or Control

Description

Map Type

Select to specify a map type for this map. The value you select determines the options available on the Map Detail page. Options include:

Application Class: maps data using an application class that you specify. Selecting this makes the application class ID and application class path fields available on the Map Detail page. Specify an extension of class SCM_SAC_XMLMAPPER:Maps:MapBase, and be certain the specified class implements method TransformXMLString().

Attribute Value: maps the values associated with a specific XML attribute. Selecting this makes the internal value and external value fields available on the Map Detail page.

Field Alias: enables the renaming of fields, such as renaming a field called business unit to BU. Selecting this makes the internal field name and external field name fields available on the Map Detail page.

Field Value: enables the revaluing of fields. For example, externally, a business unit could be called NY Operations, internally, it could be called US007. Selecting this makes the internal value and external value fields available on the Map Detail page.

Field Value — SQL: maps field values using a SQL object. The SQL objects should return two values: internal value and external value, in that order. Selecting this makes the SQL object identifier field available on the Map Detail page.

Record Alias: enables the renaming of records. Selecting this makes the internal record and external record fields available on the Map Detail page.

Values Only: sets up a simple list of mapped values that you can use from code. Selecting this makes the internal value and external value fields available on the Map Detail page.

Note: This map type is never run automatically.

XSL: maps data using XSL that you provide. Selecting this makes the XSL field available on the Map Detail page.

See Map Detail Page.

Map Level

Select All Messages to apply this map to all active messages, or Specific Message to apply this map to one message only.

This option is only available if you select a map type of application class, attribute value, field alias, field value, record alias, or XSL.

Message

Enter the specific message to map to if you selected the specific message mapping level.

Map Match Criteria

Field or Control

Description

Attribute Name

Enter a name for the attribute. The system displays this field only when you have selected an attribute value map type.

Criteria

Enter criteria used to map the data. This is only available if you have selected a field alias, field value, field value — SQL map type. Options include:

None: no criteria will be used to map the data other than that found on the Map Detail page.

Note: This value is for system use only. You must select a value other than None.

Record/Field: to map data by a specified record or field. You can choose All Records, Specific Record, and select a Record, or select a Field.

XPath: select to enter an XPath expression that will specify everything BUT the values you would like to map. Additional XPath text will be appended to your XPath based on the values specified on the Map Details page.

For example, if A and B are specified as Internal and External values, respectively, the XPath expression //RECORD_NAME/FIELDNAME would become //RECORD_NAME/FIELDNAME/text()[.='A'] for an outbound transaction.

If you select this option, enter a Pattern.

Use the Map Detail page (SAC_MAP_DEFN_DTL) to use to specify the map type detail.

Navigation:

SCM Integrations > XML Mapper > Define Maps > Map Detail

Field or Control

Description

Application Class Path

Specify an extension of class SCM_SAC_XMLMAPPER:Maps:MapBase. Be certain the specified class implements method TransformXMLString(). The system displays this field only when you have selected an application class map type on the Define Map page.

Application Class ID

Select a valid application class ID that is available at the specified application class path. The system displays this field only when you have selected an application class map type on the Define Map page.

Internal Value

Enter the value you wish to convert to on an inbound transaction or convert from on an outbound transaction. The system displays this field only when you have selected an attribute value, field value, or values only map type on the Define Map page.

External Value

Enter the value you wish to convert from on an inbound transaction or convert to on an outbound transaction. The system displays this field only when you have selected an attribute value, field value, or values only map type on the Define Map page.

Internal Field Name

Enter the value you wish to convert to an inbound field name or from an outbound field name. The system displays this field only when you have selected a field alias map type on the Define Map page.

External Field Name

Enter the value you wish to convert from an inbound field name or to an outbound field name. The system displays this field only when you have selected a field alias map type on the Define Map page.

SQL Object Identifier

Select a SQL Object Identifier. The system displays this field only when you have selected a field value — SQL map type on the Define Map page.

Internal Record Name

Enter the value you wish to convert to on an inbound record or convert from on an outbound record. The system displays this field only when you have selected a record alias map type on the Define Map page.

External Record Name

Enter the value you wish to convert from an inbound record name or to an outbound record name. The system displays this field only when you have selected a record alias map type on the Define Map page.

XSL

Enter your own custom XSL transformation. The system displays this field only when you have selected a map type of XSL on the Define Map page.

Use the Define Map Sets page (SAC_MAPSETDEFN) to use to group maps together, order them, and specify in which directions they apply.

Navigation:

SCM Integrations > XML Mapper > Define Map Sets

This example illustrates the fields and controls on the Define Map Sets page. You can find definitions for the fields and controls later on this page.

Define Map Sets page

Field or Control

Description

Map SetID

Create a map set ID to designate each map set.

Active

This option must be selected for the XML mapper to complete data transformations.

Map ID

Select a Map ID to associate with this map set. You can associate multiple map IDs with a single map set.

Direction

Enter the direction for which the selected map should apply. Options include Inbound for inbound transactions, Outbound for outbound transactions, or Both if you want the map set to be used for inbound and outbound transactions.

Arrows

Choose the order in which the maps should be run.

Use the Define Node Associations page (SAC_NODE_ASSOC) to use to associate a source node and a target node with a map set.

All maps in an associated map set will then execute using the node association. Before defining a node association, set up an Integration Broker service operation routings for your nodes.

Navigation:

SCM Integrations > XML Mapper > Define Node Associations

This example illustrates the fields and controls on the Define Node Associations page. You can find definitions for the fields and controls later on this page.

Define Node Associations page

Field or Control

Description

Map SetID

Enter a map set ID to use with the source node and target node.

Arrows

Choose the order in which the map sets should be run.