Skip to Content
Technical Articles
Author's profile photo Rashi Chowdhary

Configuring Custom Entity for custom portlet for BIB replication

Introduction:-

As a consultant we come across this scenario multiple times where client uses SuccessFactors EC as master data source and uses on-Premise SAP for further processing.

Many a times SF EC will have custom MDF portlets created for specific client requirements and we the same needs to be sent to on-Premise SAP.

In this blog we would learn how we can use configurations to map Custom MDF entities to SAP using BIB functionality.

Business Scenario:-

Every company assigns different assets when an employee joins. The details for each type of asset can be tracked easily in SF EC using a Custom MDF object. Also the same records need to go back to SAP ECC for many legacy reporting purposes.

During replication of data from SF EC to SAP ECC there are often requirements for data to flow from Custom MDF objects where there is a Parent-Child relationship at EC to infotypes at SAP.

Example for such cases would be when multiple details are to be added in EC at item level

  • Assets belonging to Company which employees are using
    • Laptop with laptop number,start date, model number
    • Cell phones with model number, year of purchase

The details are added at the Child Entity Level which is basically accessed Via the Parent entity( Laptop/Cell). In this case replication mapping is only required for the child entity.

The problem arises when we try to directly map the Child entity.This results in replication error.

Although we get the complete child entity data in payload – configuring only the Parent Entity for field mapping will not work. The metadata of the parent object does not contain fields in the child objects.

Now this sounds difficult but the above can be achieved at BIB Configuration level itself.

Solution and Steps :-

Step 1: Defining Custom Employee Central Entities for Employee Data Entities

  • In the Define Additional Employee Central Entities for Employee Data Customizing activity (view V_ECPAO_ECTMPL)
  • Enter a unique entity ID and a description. The ID should be in the customer namespace, which means that it should start with a number (0* – 9*).

Defining%20Custom%20Entities

Step 2: Create Header Entity

  • Exact API name of the corresponding entity in Employee Central needs to be used
  • Header should have Start date and End date fields
  • End date in Header should be mdfSystemEffectiveEndDate – This is a very important step for the configuration to work

Header%20and%20Child%20Entity

Header and Child Entity

Header Entity Detail

Step 3: Create Child Entity

  • Should not have the Start and End date fields and the Dependent field to be added using the Parent Entity name, and inherit field should be blank.

Child Entity Detail

Step 4 : Upload the metadata for both the Parent and Child entity

Step 5: Add End Date

For custom portlets, SAP do not have the End date field in metadata, so we need to add the End date field with the name as mdfSystemEffectiveEndDate (*) and Type as Datetime

Customizing Path for Additional fields in Metadata

Personnel Management — Integration with SuccessFactors Employee Central — Business Integration Builder — Basic Settings —  Import Metadata from Employee Central — Transport Imported Metadata and Check Metadata for File-Based Data Transfer

End%20Date%20Detail

End Date Detail

Step 6: Create a Transformation Template with Child ID

  • Customizing Path for Define Field Mapping for Employee Data

Personnel Management — Integration with SuccessFactors Employee Central — Business Integration Builder — Employee Data Integration — Define Field Mapping for Employee Data

Active%20Transformation%20Template

Active Transformation Template

 

Step 7: Add the Child Entity in the Exception node with Header CPI segment

This is a very important Step for the configuration to work

Add the Parent API in Exception –

  • CE API segment is from Parent API and Entity name is from Child

Customizing Path for Exception:

  • Personnel Management — Integration with SuccessFactors Employee Central — Business Integration Builder — Employee Data Integration — Define Exceptions for Compound Employee API query

Exception Screen

Result:-

With the above configuration steps in place, now we are ready to do the field level mapping from child entity to the infotype fields and start replication.

Here is how the end result will work with above configurations.

Example the SF EC screen to have some record on the custom portlet that needs to be moved to SAP ECC.

Custom%20Portlet%20view

Custom Portlet view

Once the employee is triggered for replication the payload would look like below having Parent/Child structure.

Payload showing Parent/Child structure

Upon Successful processing , the record gets inserted at infotype level.

Final%20Infotype%20screen

Final Infotype screen

Conclusion:-

Depending on the requirement from client, custom MDF data can also be used for different subtypes as well using the cloning technique from BIB.

The important point to note here is that this is done without writing BADI or a single piece of code and thus reducing the development efforts. It is easier and quicker as well.

Note:- This blog do not describe the complete BIB functionality and is intended for consultants having BIB integration knowledge.

For BIB knowledge the below link can be referred:-

SAP BIB Guide

Assigned Tags

      5 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Syambabu Allu
      Syambabu Allu

      Hi Rashi,

      Good Blog.Thanks for sharing.

      Thank you,

      Syam

      Author's profile photo Rashi Chowdhary
      Rashi Chowdhary
      Blog Post Author

      Thank you

      Author's profile photo Maria Velyakova
      Maria Velyakova

      Dear Rashi Chowdhary,

      The above article really add value for me. While I was testing it I have received an error that somehow I am not able to avoid. On the very last step, when I am checking the log of the employee which is transferred, I get error in SLG1  that Subtype field LEIHG not mapped for infotype 0040

      Have you ever met that error. I have tried with SAP note 2685311 but seems that the issue is not there.

      Your input will be highly appreciated!

      Regards, Maria

      Author's profile photo Rashi Chowdhary
      Rashi Chowdhary
      Blog Post Author

      Dear Maria Velyakova

       

      The error comes when infotype has fields similar to subtypes like in Address infotype we have ANSSA similar to Subtype. Here also we map address type to ANSA instead of SUBTY

      You can map the Equipment type field from EC to LEIGH  instead of SUBTY ; it would work.

      Additionally you can use cloning feature to reuse the field mapping that you define for some or all subtypes of an infotype.

       

      Hope this helps.

      Thanks

      Rashi Chowdhary

      Author's profile photo baladeba behera
      baladeba behera

      Thanks for sharing Rashi.. Nice Blog..