This blog explains how to reuse Cost Center IDs while replicating Cost Center from SAP ERP to SuccessFactors Employee Central.
Scenario
You use SAP ERP system to manage Cost Center information. This might be a separated SAP ERP FIN system or an unified SAP ERP instance.
You configure SAP SuccessFactors Employee Central system (SF EC) to manage employee data.
You need to synchronise the Cost Center information between SAP ERP system and SF EC system.
Optional: You assign Cost Center, replicated from SAP ERP, to Employee in SF EC and post this assignment to SAP ERP.
Prerequisites
You use the pre-packaged integration “SAP ERP to EC Cost Center Replication” for replication of Cost Center information from SAP ERP to SF EC system.
Optional: You use the pre-packaged 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
- SF EC: check Settings in Cost Center MDF (Metadata Framework) object
- SAP ERR: field mapping in IDoc ODTF_CCTR
- BOOMI middleware: set flag in Process Properties
- Optional: Replication of EC Cost Center assignment with Employee data.
1. SF EC: check Settings in Cost Center object
- 1. In SF EC system go to Administration Tools -> Configure Object Definitions.
- 2. Search for “Object Definition” and “Cost Center”.
- 3. There are two ID fields “externalCode” and “costCenterExternalObjectId”.
- 4. Go to Details of the field
If the Cost Center is replicated from the SAP ERP you may set the code fields to “Read only” to prevent changes in SF EC UI.
If you use field “costCenterExternalObjectId” check that it is visible.
2. SAP ERR: field mapping in IDoc ODTF_CCTR
The pre-packaged integration uses ERP IDoc (intermediate document) ODTF_CCTR for replicating Cost Center. The IDoc is delivered with AddOn ODTFINCC 600.
The Cost Center IDs are processed in IDoc structure E101ODTF_S_COST_CENTER_DATA.
ERP field | IDoc field | EC field |
---|---|---|
KOSTL (Cost Center) | REMOTE_EXTERNAL_OBJECT_ID | External Object ID (costCenterExternalObjectId) |
KOKRS (Controlling area) and KOSTL (Cost Center) | REMOTE_OBJECT_ID *is concatenated from the ERP field KOKRS and ERP field KOSTL | Code (externalCode) |
Cost Center in SAP ERP:
IDoc structure E101ODTF_S_COST_CENTER_DATA with data of Cost Center 328:
You can use the Business Add-Ins (BAdIs) ODTF_CO_REPL_IDOC_COST_CENTERS to modify the fields of the IDoc e.g. add your logic for field REMOTE_EXTERNAL_OBJECT_ID.
3. BOOMI middleware: set flag in Process Properties
If you want to replicate the field External Object ID (MDF field costCenterExternalObjectId) you need to set the parameter USE_EXTERNAL_COST_CENTER_ID in BOOMI middleware iFlow “SAP ERP to EC Cost Center Replication”. The field External Object ID is not replicated with Default setting. The field Code (MDF field externalCode) is replicated per Default.
The field External Object ID will be also replicated to SF EC.
Replicated Cost Center in SF EC:
4. Optional: Replication of EC Cost Center assignment with Employee data
You may assign Cost Center to Employee in EC Job Info. If you configured the pre-packaged integration for Employee master data replication “EC to EC Payroll Employee Replication” and for the Employee Organizational assignment “EC to ERP Organizational Management” you have two options to specify what EC field will be used by the integration as a Cost Center ID:
- EC field External Object ID
- EC field Code.
If you want to use EC field External Object ID you should change the Parameter in Process Properties in BOOMI middleware. The default setting uses EC field “Code” as a Cost Center ID.
Process “EC to EC Payroll Employee Replication”:
Process “EC to ERP Organizational Management”:
Cost Center assignment in Employee Job Information in SF EC:
In this example I set the BOOMI Parameter to process the External Object ID.
The field External Object ID is processed in ERP inbound message:
If the length of the remote costCenter ID is 10 characters, the integration assumes that the remote costCenter ID represents ERP Cost Center ID (field KOSTL).
If the length of the remote costCenter ID is exactly 14 characters, the integration assumes that the first four characters represent a controlling area (field KOKRS) and the other ten characters represent the Cost Center ID (field KOSTL).
In these cases no additional mapping in table “Cost Centre Key Mapping” (PAOCFEC_KMAPCOSC) is required.
The inbound processing posts Cost Center assignment in ERP PA (Infotype 0001) and OM (Infotype 1001).
Cost Center assignment in SAP ERP Infotype 0001:
Cost Center assignment in SAP ERP Infotype 1001:
Please also refer to Integration Guide „Replicating Cost Centers from SAP ERP to Employee Central” on the SAP Help Portal at http://help.sap.com/hr_ec/ -> Integration Content -> SuccessFactors and SAP ERP: Full Cloud HCM.