Professional Documents
Culture Documents
Each SAP application uses its organizational units to structure data. Organizational units are assigned to
each other to be able to process the data in an integrated way.
For each MC scenario, SAP predefines the most suitable unit to be used
as the selection unit, e.g. for SAP ERP to SAP S/4HANA the company code.
Company code
Open items
When starting the selection, an
… integrated selection engine
Materials derives the related organizational
units.
Plant As long as you use SAP delivered
Customers
migration objects, the engine
ensures that all data which belongs
Sales organization
to the selected migration objects of
Cost centers this company code(s) is selected.
Controlling area
Migration object
Source tables Define selection Migration object Transformation rule / Function module
Define derivation of instance mapping
organizational unit
Migration object
Source tables Define selection Migration object Transformation rule / Function module
Define derivation of instance mapping
organizational unit
3. Defines from 4. Filters derive 2. Contains the data 5. When starting the 1. Expects 6. Data is created
which tables in the relevant which is necessary to simulation or migration, dedicated fields in respectively
the source organizational feed the function the transformation rules order to be able to posted in
system the units from which module. are applied to the fields create a record in SAP S/4HANA
data is read in the data is of the instance. The the target system
order to create selected. More transformed instance is
a migration selection options passed to the API.
object instance exist.
As long as you use the delivered migration objects, SAP ensures that all relevant records (chosen
organizational units and chosen migration objects) are selected. The derivation of the dependent
organizational units is also already part of the delivered objects.
The migration cockpit uses transformation rules to change values that are migrated from source fields to
target fields. You can use existing rules or create your own rules and assign them to the target fields in the
Field Mapping.
▪ Until release 2020 (incl.), the Selection step also created mapping value proposals. So after you executed the
selection from the source system, the mapping values were visible. With release 2021, mapping values are
created in the separate activity Prepare Mapping Tasks.
▪ In the migration cockpit, only the mapping tasks which have values (step: Prepare Mapping Tasks) are
displayed. If you go to Download Mapping Templates, all mappings which are basically available for this object
are offered. In transaction LTMOM, you also see all mapping tasks.
▪ Currently, there is no lock functionality for mapping values. Manual value editing is always possible. Only the
upload of mapping is blocked if at least one record for the migration object has already been successfully
migrated (or successfully partly migrated in case of multi-step objects).
▪ Source code rules and MOVE rules are not displayed in the migration cockpit (under mapping tasks), only in
transaction LTMOM.
▪ The SKIP rule (influence selection) is a source code rule.
▪ Transformation rules can be transported. Values are never transported, they can be downloaded and uploaded.
▪ With 2021, copy and deletion of transformation rules is possible and can be transported.
Mapping values can be downloaded/uploaded in the migration cockpit (since 2020). Mapping download/upload
in transaction LTMOM (since 1909) is no longer possible with release 2020 FPS1.
Upload/download all
templates and / or mappings
for your project! Upload / download Upload / download
mapping templates mapping values
Migration Cockpit
If there are field extensions in the source system (custom-own fields resp. Z-fields) the migration cockpit
recognizes this.
Transaction LTMOM displays these fields within the migration object under “source tables” as source fields.
In order to migrate such an extension, the extension must exist in the target system too.
If and how the custom-own field can be migrated to the target system depends on how the BAPI used in the
migration object is designed.
For function modules, three different concepts exist:
▪ Function modules which contain includes or append fields
▪ BAPI function modules with type 1 extension fields (e.g. BAPI_MATERIAL_SAVEREPLICA)
▪ BAPI function modules with type 2 extension fields: with or without X-fields
In all cases, the includes and append structures have to be edited by the customer (transaction SE11).
The user needs deep DDIC knowledge and ABAP development authorization.
If you want to create an own function module, see SAP Note 2590165.
The SAP S/4HANA migration cockpit is able to migrate custom developments such as
▪ additional Z-fields in standard objects or
▪ completely individual custom objects
If a simple 1:1 table transfer without the need for transformations, plausibility and
consistency checks is required, you should consider developing an own RFC-enabled
function module (currently used API just RFC-enabled) and a Z program which retrieves
the data from the Z table and transfers it 1:1 from sender to target.
© 2023 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 12
Getting started with the migration object modeler – Direct transfer
Copy and delete migration objects
With release 2020, you can copy migration objects from a template (from the objects delivered by SAP) and
copy migration objects within the same project. Deleting objects is also possible.
The “Migrate data directly from SAP system” approach is available since release 1909.
Find below important new features.
Delete objects x x x
open@sap.com
Follow all of SAP
www.sap.com/contactsap
Business scenario
Demo – Part I
Imagine migration object “CO – Cost center” only migrates master data in the logon language (this was the
case until release 2021). In order to migrate texts in other languages too, an additional migration object is
needed.
We use this example to demonstrate how to create an own migration object.
SAP ERP
source system
If you have specific requirements that are not covered by the migration objects provided by SAP, you can
create user-defined migration objects.
Choose: Project → Create Migration Object → User-Defined. This
path opens a wizard which supports you in creating your own object.
In the Source Tables step you define the table(s) from which the selection will read the data. You can also use
customer-own tables here.
Table CSKT does not contain all the fields that are needed to feed the respective BAPI (field valid-from is
missing), so we need a second table CSKS to fill all fields. CSKS is defined as a child table in this data model.
Position the cursor on table CSKT and choose Add Child Table
Parent – child
For this example, define CSKS as child
relationship
table of CSKT
Proposal button
Now the foreign key relationship between
parent and child table has to be defined. For
each CSKT key field, assign the respective
CSKS field.
In this step, you can define simple data selection settings for your migration object. In our example, we use
“Define selection later” as we will have a more detailed selection.
In this step, you define which fields determine a migration object instance in a unique way. In this example, the
fields Language Key, Controlling Area, Cost Center, and Valid To Date define one instance unambiguously.
Assign the function module which will be used to post or create the data in the SAP S/4HANA target system.
You can also assign an own custom API. In addition, define here the parameters for a possible simulation
mode. Check the function module documentation to get the details about a possible simulation functionality and
how to fill parameters.
The API call results step offers all exporting parameters and
table parameters of the function module you assigned in the
previous Target API step. The proposal function suggests
the proper evaluation method.
Back in the migration cockpit, you see the newly created migration object.
This migration object is processed in the same way as the migration objects delivered by SAP.
open@sap.com
Follow all of SAP
www.sap.com/contactsap
Demo – Part II
A filter is a collection of values of the same type that is stored centrally for your project, and therefore available
for all migration objects assigned to the project. A filter can be, for example, company code, controlling area,
plant, …
After having finished the steps in the migration object wizard, some more details need to be edited directly in
transaction LTMOM. Then the new migration object is ready to be used. Under Source Tables you can
influence the selection and define filters.
Go to Source Tables and double-click table
CSKT to open the window on the right-hand side
The arrow
turns green
Do the same for table CSKS:
go to field BUKRS and assign filter BUKRS.
Entries will be
selected only for
this cost center
Under Structure Mapping you define which information is transferred from the source structure to the structure
of the function module.
Drag and drop the source structure CSKT to the target structure
(to the function module BAPI_COSTCENTER_CHANGEMULTIPLE)
© 2023 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 10
Creating your own migration object (II)
LTMOM – Structure mapping – Foreign table data access
Foreign table data access defines how the records of child table CSKS will be selected. In the present data
model, for each record in CSKT there is only one dedicated record in CSKS. So the option “Read any line” is
chosen.
Click set up
In Field Mapping you map the fields of the source tables to the fields of the target structure / the function module.
Only the mapped fields are shown. You can
change it to “All Fields” if you want to get all.
Transformation type
is currently “Move”.
This means all values
are moved unchanged
1:1 from the source
system to the target
SAP S/4HANA system
Drag and drop the source fields on the left-hand side (from CSKT and CSKS) to the target fields of
the function module BAPI_COSTCENTER_CHANGEMULTIPLE (on the right-hand side). Fields
BUKRS and DATAB are moved from table CSKS, all other fields from CSKT. Be careful to expand
the correct table (!) under Source Tables in order to choose the fields from the correct table!
© 2023 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 12
Creating your own migration object (II)
LTMOM – Field mapping – Assign mappings for KOKRS and BUKRS
For fields KOKRS and BUKRS we need not only 1:1 moves but mappings (from source value to target value). So we choose
another mapping type for them.
Do the same for assignment CSKS-BUKRS. Use rule “MAP_BUKRS” with source value CSKS-BUKRS. The upcoming
popup (more settings to be maintained) can be ignored for our example. It would only be necessary if values are passed
over for the same variable in several steps within one object. But it does not harm anything if maintained.
© 2023 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 13
Creating your own migration object (II)
LTMOM – Field mapping – Create an own rule
You can also create own rules on project or object level: fixed values, value mappings, or source code rules.
Right-click on the respective line.
Right-click on the
respective line to open
the Create window
The field mapping for our example looks like this now. 8 field mappings, 2 of type “mapping”, 6 of type “move”.
The definition of the migration object is now complete. Save it and exit transaction LTMOM.
© 2023 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 15
Creating your own migration object (II)
Migration cockpit – Selection result
We execute the selection in the app. As result, we get 3 instances – 1 instance (E, F, I) for each text.
The custom-created migration object can be processed as all other objects.
We execute the simulation and then the migration. Three instances are migrated successfully.
open@sap.com
Follow all of SAP
www.sap.com/contactsap
Filters
Table fields
Inherit restrictions
Skip rule
Restrictions
As long as you use the delivered migration objects, SAP ensures that all relevant records (chosen
organizational units and chosen migration objects) are selected. The derivation of the dependent organizational
units is also already part of the delivered objects.
Company
codes
Migration
objects
This KBA provides technical deep-dive insight into the selection logic: 3249988
Internal tables
CSKS
CSKT
In your migration object, under Source Tables, you can change the selection for this object. The standard
select option dialog is offered for each table field of the source tables.
If you use filters and/or restrictions on table fields, you also have to define how the selection for each source
table at level >=2 impacts other tables.
▪ Child tables only: the selection settings are restricted only to the current table. There
is no impact on the selection result from the header table. But all its child tables are
affected. All child tables will automatically be set to the same option and cannot be
changed.
▪ Parent and child tables (default): the selection result is aggregated level by level
upwards until it reaches the header table.
The example below for migration object product explains the logic of this setting. This example does not
represent the complete data model; it is a reduced and schematic representation!
Detailed view on tables
MARA contains no field which is suitable for an
MARA organizational derivation.
MARC
MATNR
MATNR WERKS
In order to migrate only the material numbers which
AAA
belong to the relevant company codes, the filter
AAA 1000
WERKS is set on subordinated table MARC. The filter
BBB AAA 2000
Source tables and filters WERKS finds in MARC all MATNR which are assigned
BBB 2000 to plants belonging to the chosen company codes.
CCC
BBB 3000
The setting Parent and child tables has to be set. This
MARA DDD CCC 4000
means only when a MARC-MATNR record is relevant is
DDD 5000 the MARA-MATNR record selected too.
… If Child tables only is set, all MARA-MATNR records
WERKS_FILTER
would be selected, regardless of whether a suitable
MARC WERKS WERKS BUKRS: 1000
MARC-MATNR is found. This will lead to errors during
1000
… simulation/migration where MARA records have no
2000 corresponding MARC records.
© 2023 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 9
Focus topic selection: modeling capabilities
Ways to influence the selection – BAdI for selection
The BAdI allows you to apply additional logic to the data selection from the SAP source system. If the
filtering logic or simple selection criteria offered in the migration object modeler are not sufficient for you
to support your data selection requirements, you can implement ABAP code in the source system using
this BAdI.
Find details in KBA 3092921.
BAdI for selection
In your migration object, under Source Tables, you can use the Selection Settings button to access the so-called skip rule.
You first generate the rule. It is of type “source code” and will be displayed under this section in your object. With the pen
button you access the source code. Here, you write your individual coding to skip items from the selection. As the skip rule
consumes more runtime in comparison to other possibilities, only use this rule if necessary.
open@sap.com
Follow all of SAP
www.sap.com/contactsap
Business scenario
Demo
Company
codes
Migration
objects
Migrate profit center data using the migration object CO – Profit Center.
From the source ERP system, only profit center data shall be selected where the third character of the profit
center is equal to 1.
As soon as you start adapting the selection, you are responsible for ensuring a consistent
selection and a successful migration.
Refer to SAP Note 2481235 for more details.
Migration object CO – Profit Center has table CEPC as its root source table.
© 2023 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 4
Focus topic selection: influence selection using coding
Business scenario
The profit center data in this scenario is simplified: Profit centers start with “YB” and are followed by three
numbers. Therefore, the scenario could be rephrased to selecting all profit centers between YB100 and
YB199.
There are limitations to choosing this option: Profit centers are alphanumeric.
For more information on changing the selection settings, see KBA 3249988 or the info button.
After data is selected from the source system it is possible to skip migration object instances such that they
are excluded from further processing in the SAP S/4HANA migration cockpit.
As this procedure consumes more resources than other selection options, only use this rule if
necessary.
For more information on how to exclude object instances, see KBA 3249988 or the info button.
In this unit we will demonstrate how the business scenario can be done using a BAdI
implementation.
Developing knowledge or help from a developer expert is advised when using this option.
1 Provide a name and description for your enhancement implementation on the creation popup.
2 Click Confirm.
2 Provide a name for the BAdI implementation and the new implementation class.
3 Click Confirm.
2
1
3 Create a new
filter combination.
On the popup screen, provide a filter value name for filter PRESEL_BADI_FILTER_VALUE
with comparator ‘=’.
The system will display a popup informing you that the interface implementation is still missing.
It can be ignored for the moment.
Lastly, you need to implement the required logic for the data selection in the class that you have created.
2
3
© 2023 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 18
Focus topic selection: influence selection using coding
Create BAdI implementation
The system will display a popup to inform you that the method has not yet been implemented.
Confirm that you want to create the implementation.
The importing and changing parameters are filled by the system during the call of the BAdI implementation.
During the selection of one migration object the BAdI implementation is called
▪ After other selection criteria (filtering logic, additional selection criteria etc.) is applied to the data
▪ For all source tables for which the BAdI for selection has been activated
The same BAdI implementation is used for all migration objects within one migration project.
It is advised to use a different BAdI implementation for different migration projects as it is not possible
to find out which migration project the migration object belongs to.
Importing parameter IV_DATAMODEL_COMMENT can be used to find out for which migration object and
source table the BAdI is called.
It contains the information that can be retrieved via LTMOM concatenated in one string:
‘<technical migration object name>-<current source table name>’
When multiple database source tables of the same kind are created, a substitute name must be
provided. This information is stored in importing parameter IV_DATAMODEL_COMMENT.
The information about the actual database table is stored in importing parameter IV_TABLE_NAME.
The changing parameter CT_DATA contains the data that has been selected so far.
Other selection criteria (filtering logic, additional selection criteria etc.) have already been applied to it, so
CT_DATA does not contain all database table entries existing in your source system at runtime.
Changes in CT_DATA will be used for the rest of the selection process.
The changing parameter is not of the same type as the source table.
It is of a different type and only table key fields of the source table can be used.
Make sure to activate and save the class as well as the BAdI implementation.
Now we need to activate the BAdI selection exit for our migration project.
The BAdI implementation method will be called during the selection of all source tables for which the BAdI for
selection is activated in the selection settings. However, it is up to the implementation in the method
PROCESS_DATA whether or not the data is changed.
Note that with activation of the BAdI for selection for a migration project, the BAdI for selection will
automatically be activated for all source tables for which the following is true
▪ The source table is the root table of the data model
▪ The source table has at least one selection criterion assigned to it
▪ At least one selection criterion is assigned to one of the source table’s child tables
(if the selection criteria scope covers parent tables)
For all other source tables for which the BAdI exit is not activated by default you must activate it manually.
You can manually activate the BAdI exit via the Selection Settings popup for a source table.
Finally, go to the SAP Fiori “Migration Cockpit” app and start the selection of the migration project.
Make sure that you are not editing the migration object in transaction LTMOM.
Otherwise, you will be locking the migration object and the selection will fail.
open@sap.com
Follow all of SAP
www.sap.com/contactsap
versus
REENGINEERING SAP S/4HANA Cloud,
with data migration Selective data private edition
Customer tailored Selective business transition SAP S/4HANA
process optimization
Tool of choice for Preconfigured Integrated in SAP Guided and safe Flexible and
migration to SAP migration content Activate migration extendable
S/4HANA specific to methodology
SAP S/4HANA
Part of SAP S/4HANA Comprehensive set of Proven methodology Step-by-step guidance Migration object modeler
and SAP S/4HANA preconfigured migration integrated in through the migration for custom requirements
Cloud (included in these objects, such as SAP Activate roadmap process
licenses) customers, suppliers, Ability to extend existing
and so on Best practices Preconfigured migration SAP migration objects
Ready-to-use solution objects
Automated mapping Integration of custom
Supports customers with between source data Data validation to objects
new implementations and SAP S/4HANA ensure high data quality
target values and consistency
Facilitates initial data
load, ensuring a Lower cost, project
consistent end user duration, and risk for
experience and simplified customers
data migration
© 2023 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 3
Summary and further information
Sources to support you in your migration process
SAP Activate Methodology SAP Best Practices Data Migration Landing Page
(Roadmap Viewer) via Process Navigator on SAP Help
▪ Access implementation guidance for ▪ Access and download SAP Best ▪ Access documentation – Application
your digital transformation Practices content Help
▪ View and download SAP Activate ▪ Power your project with ready-to-run ▪ View additional slide decks and training
methodology assets and accelerators business processes information
▪ https://go.support.sap.com/roadmap ▪ https://me.sap.com/processnavigator ▪ http://help.sap.com/S4_CE_DM
viewer/#
Migrate Data Using Staging Tables Migrate Data Directly from SAP System
(Direct Transfer)
▪ Staging tables are created automatically in ▪ Connect source system (ABAP-based SAP source systems)
SAP HANA DB (either locally or in a remote system) via RFC connection
▪ Populate these staging tables with business data ▪ Selection
using: – Based on predefined selection criteria (for example
– XML template files company code for ERP source system) and selected
– CSV template files migration objects
– SAP or third-party ETL tools – Can be adapted with the SAP S/4HANA migration object
modeler
▪ Supports data migration scenarios from
SAP ERP, SAP AFS, SAP APO SPP, SAP CRM, SAP EWM
Central landing page with information about the SAP S/4HANA migration cockpit
Training Material
Standard presentation Migrate Your Data to SAP S/4HANA
Link List – Available migration objects: link
Further Useful Release comparison of migration object templates Staging*
Documentation
Migration of Financial Accounting Master and Transactional Data
Video Library for data migration
Click-through demo: Introducing the SAP S/4HANA Migration Cockpit**
Demo scripts for SAP S/4HANA migration cockpit (based on 2022 FPS01)
▪ File approach (bank)
▪ File approach (material)
▪ LTMOM – file approach (cost center texts)
▪ Staging approach (G/L accounts)
▪ Direct transfer approach (cost centers and activity types)
▪ LTMOM – direct transfer approach (cost center texts)
▪ Direct transfer approach (material)
▪ Direct transfer approach (vendor, CVI)
https://blogs.sap.com/2020/04/27/sap-s-4hana-migration-cockpit-
create-your-test-system/
open@sap.com
Follow all of SAP
www.sap.com/contactsap