Mapping Fields and Values for Foundation Objects

Objective

After completing this lesson, you will be able to map fields and values for foundation object data.

Transformation Template Group and Templates for Foundation Objects

To enable the data extraction programs to extract the correct SAP S∕4HANA information for the correct Employee Central fields, you must map SAP S∕4HANA fields to Employee Central fields.

To map fields, you go to the Define Field Mapping for Foundation Objects Customizing step, which has the VC_ECPAO_MAP_FO view cluster assigned. The configuration in this view cluster is done in several steps:

  1. Create at least one transformation template group. A template group bundles all field mappings that you want to use when running the data extraction program. This is the entity that you specify on the program selection screen. From the transformation template group, the data extraction program determines the information that it must extract data from SAP S∕4HANA fields and map it to Employee Central field IDs.

  2. Create at least one transformation template for your transformation template group. A transformation template groups information from the SAP S∕4HANA system that belongs together logically. It is the SAP S∕4HANA counterpart of the Employee Central entity.

  3. Define a primary mapping for each of your transformation templates. This means that you choose Employee Central field IDs from the Employee Central entity assigned to the transformation template. Then, you map suitable SAP S∕4HANA fields to these Employee Central field IDs

Primary Field Mapping for Foundation Objects

You can choose Employee Central fields from the Employee Central data model that you've uploaded to the SAP S∕4HANA system. You then map suitable SAP S∕4HANA fields to these Employee Central field IDs.

Context

To define a field mapping for each transformation template, go to the Primary Mapping view of the VC_ECPAO_MAP_FO view cluster.

Note

There are predefined standard mappings, which are automatically added to the templates you use and aren't available for configuration in this Customizing activity.

Here's how to map fields:

Procedure

  1. Choose an Employee Central field from the assigned Employee Central template.
    • For Mapping mode as Table Mapping, the system allows to choose only a set of approved tables.

      Hint

      The system table ECPAO_TABLE_LIST contains the currently supported configuration tables.

    • While creating a foundation object entity, a primary table is assigned along with one key field, which identifies the foundation object.

    • When configuring the table mapping for the above FO entity, only approved tables with the same key as defined previously must be used. Approved tables with different keys cannot be used.

  2. Map each Employee Central field to an SAP S∕4HANA field using a suitable mapping mode:
    • When you select the mapping mode Table Mapping, you can map an Employee Central xxxxx.
    • When you select the mapping mode BAdI Mapping for Integration/Migration to EC, you can use an implementation of the Mapping of EC and ERP Data for Data Replication to EC (EX_ECPAO_EMP_DATA_EXTRACT_OUT) BAdI to define the field mapping.
  3. If the value from the SAP S∕4HANA field needs to be converted into an Employee Central value, enter the value mapping entity that you have defined in the Define Value Mapping Entities Customizing step.

    Note

    You can define the value mappings for this entity directly from here by choosing Define Value Mapping Entries.

Use the Sample Content for Foundation Objects

SAP provides sample content for different use cases in the Define Field Mapping for Foundation Objects customizing step, which you can copy and adapt to your needs.

You can copy the sample content for the required foundation objects according to your needs.

Steps

  1. Create a transformation template group and select the sample content that you want to use for it.

  2. In your transformation template group, create transformation templates for all entities you want to use and assign the corresponding Employee Central entities. You can create the transformation templates by choosing Copy Sample Content at each transformation template level. You can use the Copy Sample Content button to copy the transformation templates and the corresponding Primary Mapping configurations for the relevant Employee Central entities. To see the entries copied to the Primary Mapping view, to save and view all the configurations, choose Save. Which field mappings are copied depends on the sample content you have selected for the transformation template group.

  3. If needed, adapt the copied sample content to suit your requirements. You can, for example, delete mappings that you don't need, change the mapped field, or add new mappings.

Result

Once you have made custom entries in the Primary Mapping view (either by copying and adapting the sample content or by making your custom entries from scratch), you can no longer copy the sample content. If you have defined custom mappings and decide that you want to use the mappings provided by the sample content instead, delete the transformation template and create a new template.

If you have already defined field mappings in the previous releases, you can continue to use them without any changes. However, if you want to replace your custom mappings with mappings provided with the sample content, create new transformation templates for all entities for which you want to use the sample mapping. Then continue as described previously. Remove your existing transformation templates for the same entities from the transformation template group or clear the Is Active checkbox for them so that the new transformation templates are used instead.

Value Mapping Entities and Details

A value mapping entity combines a set of value mappings for a specific purpose.

Context

You define value mapping entities in the Define Value Mapping Entities Customizing step (view V_ECPAO_VALUENTY). The easiest way to create value mapping entities is to copy the sample entities by choosing the Copy Sample Value Mapping pushbutton. You can also create country specific value mapping entries and create a new value mapping entity using the Create Value Mapping Entity and Define Ctry. Spec. Value Mapping Entries pushbuttons from the primary mapping details screen.

How to copy sample value mapping content.

You'll get a list of all standard entities provided for the integration, which you can adjust to your needs.

Defining Value Mapping Details

The value mapping details actually map SAP S∕4HANA values to the corresponding Employee Central values.

Procedure

  1. Go to the Define Value Mapping Details Customizing activity (view V_ECPAO_VALENTY).
  2. Map SAP S∕4HANA keys and the corresponding Employee Central keys.

    If the value mapping entity has a picklist ID and a SAP S∕4HANA value help assigned, you can select suitable picklist values in the EC Key field and corresponding input help values in the ERP Key field.

Mapping from an SAP S/4HANA value to an Employee Central value

You can also enter the wildcard * in the ERP Key field. If only the wildcard is defined in the value mapping details, any SAP S∕4HANA value will be mapped to the Employee Central key for the field that uses this value mapping entity. If the wildcard is defined in addition to specific SAP S∕4HANA keys, the system first checks for the specific keys. If an Employee Central key is mapped to a specific SAP S∕4HANA key, this mapping is used. For all other SAP S∕4HANA values, the Employee Central key mapped to the wildcard is used.

Results

The data extraction programs can now use the value mappings. When extracting data, they will replace the SAP S∕4HANA keys by the assigned Employee Central keys if a value mapping is defined for the corresponding field mapping. If no value mapping is available, they won't map any values for the specific field and use the values from SAP S∕4HANA as they are.

Replicate Foundation Object Data from SAP S4HANA to Employee Central

Summary

  • Mapping is done in the VC_ECPAO_MAP_FO view cluster by creating transformation template groups and templates, which bundle the required field mappings for data extraction and replication to Employee Central.
  • Employee Central fields are mapped to SAP S/4HANA fields using mapping modes such as Table Mapping (limited to approved configuration tables with matching keys) or BAdI Mapping for custom integration/migration logic.
  • SAP provides sample content for standard foundation objects, which can be copied and adapted as needed. Users may also create custom mappings to suit specific business requirements.
  • Value mapping entities are defined to translate SAP S/4HANA field values to corresponding Employee Central values, supporting both standard and country-specific scenarios. Wildcards can be used for flexible mapping.
  • Once mappings are configured, the data extraction programs use them during migration or replication, replacing SAP S/4HANA keys with Employee Central keys according to the defined value mapping; if no mapping is set, SAP S/4HANA values are used directly.