Skip to Content
Author's profile photo Olga Kreindlina

SAP ERP – SF Employee Central prepackaged integration: add company code for Cost Center replication

Do you replicate Employee assignments to Cost center from SAP SuccessFactors Employee Central (EC) to ERP HCM?

Then you need to ensure that only the Cost centers that belong to the Employee’s company could be assigned to Employee in EC.

This input validation in EC prevents the replication error in ERP HCM.

This blog explains how to adjust the prepackaged integration “SAP ERP to EC Cost Center Replication” to replicate the ERP Cost Center fields Company Code and Person Responsible to EC Cost Center.

If the Company code is provided in EC Cost center object, you could  filter by company in Employee Job Info or/and Position portlet to assign the valid cost center to the employee/position.

Replication of Person Responsible field is optional.

Example: Cost center “UK Marketing” is assigned to Company “Ace UK”  via replication as described in the blog:


Validation in Employee Job Info based on assigned Company: only Cost centers of company “Ace UK” are proposed for assignment:

Validation in Position Portlet based on assigned Company:



You use SAP ERP system to maintain the Cost center information. This might be a separated SAP ERP FIN system or an unified SAP ERP instance.

You need to synchronise the Cost center information between SAP ERP system and SF EC system.

You use the prepackaged integration “SAP ERP to EC Cost Center Replication” for replication of Cost center information from SAP ERP to SF EC system.

You could use Hana Cloud Integration (HCI) or BOOMI middleware prepackaged content. This blog describes configuration in HCI.


You configure SAP SuccessFactors Employee Central system to manage employee data.

You assign Cost center, replicated from SAP ERP,  to Employee in SF EC and replicate this assignment to SAP ERP.

You use the prepackaged integration for Employee master data replication “EC to EC Payroll Employee Replication” and for the Employee Organizational assignment “EC to ERP Organizational Management” to  replicate Employee data  and Cost center assignment to SAP ERP.

Main steps to process:

1.  SAP SF EC: create custom fields in Cost center object

2.  SAP ERR: enable mapping of ERP field Company code to EC field Company code (if IDs are different in the systems)

3.  SAP HCI middleware:  set Parameters for custom fields created in EC.

1. SAP SF EC: create custom fields in Cost center object

1.1  Create custom field for ERP Company and ERP Person Responsible.

ERP field Company Code should be mapped to the EC field Company (Legal Entity) to enable filtering/validation by Company while assigning Employee to the Cost center.

This validation is important if the Employees and their Cost center assignments are replicated to the ERP.

Replication of ERP field Person Responsible is optional. This field is not validated in EC and serves for information.

The EC Cost center portlet doesn’t have standard fields for Company and ERP Person Responsible.

In SF EC system go to Administration Tools -> Configure Object Definitions



1.2  Search for “Object Definition” and “Cost Center”


1.3  In my example I create custom field cust_companyCode for Company code (Data Type: Generic Object; LegalEntity) and custom field cust_respManager

      for Person Responsible (Data Type: String) in EC: 





1.4  Refresh OData API ❗

In SF EC system go to Administration Tools -> Search for “OData API Metadata Refresh and Export”.

Refresh Metadata.


2, SAP ERR: enable mapping of ERP field Company Code to EC field Company Code

2.1  Apply SAP Note 2255967 e.g. with ERP transaction snote.

2.2  Create BADI Implementation for mapping ERP field Company Code to EC Company Code.

The example implementation provided in SAP Note 2255967 uses mapping in the Customizing table PAOCFEC_KMAPCOMC:


In my example the ERP Company Code 2000 is mapped to EC Company Code  ACE_GBR.

If you use distributed system landscape and your SAP FIN system and SAP HCM (with customizing table PAOCFEC_KMAPCOMC) are in different instances you have to maintain RFC connection to your HCM instance.

Per default the BADI implementation checks the mapping in PAOCFEC_KMAPCOMC locally: iv_rfc_destination = SPACE in the coding below.

2.2.1  Call transaction SE18 -> Enhancement Spot ODTF_CC_REPLICAT_IDOCS_MODIFY


Choose ODTF_CO_REPL_IDOC_COST_CENTERS -> create Implementation e.g. ZZ_MODIFY_CC_COMPANY_ID.


2.2.2  Create Implementing Class e.g. ZCL_MODIFY_COMPANY_CODE

/wp-content/uploads/2016/02/pic11_892665.png  Go to Tab “Attributes” -> create Attribute “go_map_company_code” and refer it to Associated Type CL_ODTF_EC_MAP_COMP_CODE_EXMPL, which is provided with SAP Note 2255967:

/wp-content/uploads/2016/02/pic12_892666.png  Go to CLASS_CONSTRUCTOR and create e.g. the following code:

IF NOT go_map_company_code IS BOUND.

CREATE OBJECT go_map_company_code.


/wp-content/uploads/2016/02/pic13_892670.png  Go to Method IF_ODTF_CO_REPL_IDOC_COST_CENT~MODIFY_COST_CENTER_EXTRACTOR

Enter e.g. the following code:

IF go_map_company_code IS BOUND.
= SPACE ).

= it_sel_cost_center
= cs_cost_centers_idoc ).

2.2.3  Save and activate the created Implementing Class and Implementation


3. SAP HCI middleware:  set Parameters for EC custom fields

3.1  In your HCI tenant go to Design. Choose “SAP ERP to SuccessFactors Employee Central Cost Center Replication” -> Configure


3.2  In Configuration go to tab “Parameters”  and enter the custom fields that you created in Step 1 in EC.


3.3  Save and Deploy the changes.

4. Optional: Test the replication of Cost center with added fields

In ERP I have created Cost center OL_CC_01 in Controlling area 1000 with Company Code “2000” and Person Responsible “Olga”.


ERP Company Code “2000” is mapped to EC Company Code “ACE_GBR” in Customizing Table PAOCFEC_KMAPCOMC.

You could replicate Cost center using ALE Change Pointers or manually e.g. with report ODTF_REPL_CC.

As the prepackaged integration uses IDoc technology, Cost center IDoc is created with replicated fields:


In EC go to Manage Data .> Cost Center -> enter “OL_CC_01″.

The Cost center fields Company ID and ERP Resp Manager are successfully replicated from ERP into EC Cost Center.


Please also refer to Integration Guide „Replicating Cost Centers from SAP ERP to Employee Central” on the SAP Help Portal at -> SuccessFactors and SAP ERP: Core Hybrid HCM -> Replicating Cost Centers from SAP ERP to Employee Central.

Check other blogs relatedt to prepackaged integration of Cost Center:

Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Siddharth Rajora
      Siddharth Rajora

      Olga Excellent blog and explaining all so clearly. very helpful

      Author's profile photo Mariana Uzcategui
      Mariana Uzcategui

      Thank you so much Olga, was really really helpful!!! 😆 😆

      Author's profile photo Former Member
      Former Member

      Hi Olga,

      Thank you, it was helpful, but I jave one question... Could you please explain with more details what we need to do to achieve the proper filter in Job Information Portlet and Position object using the custom field created for legal entity? All the steps decribed above were followed but the cost center list is shown complete.

      Thank you

      Kind regards.

      Author's profile photo Olga Kreindlina
      Olga Kreindlina
      Blog Post Author

      Hi Ibzan,

      Thanks for your feedback.

      To filter Cost Centers in Position portlet please call EC Admin Center -> Configure Object Definition -> Position.

      Select field costCenter -> Details.

      Add your custom field for company code e.g. cust_companyCode under Field Criteria as shown below.

      Best regards,



      Author's profile photo Former Member
      Former Member

      Hi Olga,

      Thank you so much. Very helpful your instructions.

      Kind regards,


      Author's profile photo Nicolas Herrera
      Nicolas Herrera

      Hi Olga,

      Thank you very much for your post this has been very valuable.

      Still I have a question: following documentation the Custom field in EC must not be a navigational field.... Then how can we still have an association Legal Entity - Cost Center?

      Thank you!

      Kind regards.


      Author's profile photo Daniel Blug
      Daniel Blug

      Hi Olga,


      great blog! I have a question! Is this also possible for events and event reasons? E.g. in SAP ERP HCM you got the event New Hire with ID 01 and the event reason New Hire with ID 01 and for the event Rehire with ID 02 and the event reason Rehire with ID 01. In SuccessFactors you need to have an unique ID for every event reason. How do I map the events and event reasons? Do you think it is possible to do this similar to the cost center replication? To give the event Rehire with the event reason Rehire the code 0201 in SuccessFactors and replicate this code into the two different fields (event and event reason) into SAP ERP HCM?