Create New Custom Migration Object Using LTMOM Docx 1739526746
Create New Custom Migration Object Using LTMOM Docx 1739526746
INTRODUCTION
As we know, SAP has pre-delivered objects in LTMC, but there is master data or transactional data that does not yet
have LTMC objects, such as service master. In this post, we will create a custom LTMC object for uploading the CROSS
SELLING (VB41) using LTMOM with A BAPI.
Let's break down how to create a custom migration object using LTMOM (Legacy Transfer Migration Object Modeler)
in SAP S/4HANA, specifically for cross-selling data (VB41) using a BAPI. This is a common task when standard
migration objects don't cover your specific needs.
1. Access LTMOM: Log into your SAP S/4HANA system and use transaction code LTMOM to access the Legacy
Transfer Migration Object Modeler.
2. Create a New Migration Object: Click on the "Create" button (or similar) to start creating a new migration
object.
3. Provide Basic Information:
o Object Name: Give your custom object a descriptive name (e.g., Z_CROSS_SELLING). Use the "Z" or "Y"
namespace for custom objects.
o Object Description: Provide a clear description of the object.
o Application Component: Assign the object to the appropriate application component (e.g., SD for
Sales and Distribution).
4. Define Structure: This is where you define the structure of the data you'll be migrating. You have two main
approaches:
o A. Using a BAPI Structure: This is your chosen method. You'll need to know the BAPI structure used
by the BAPI you'll be calling (e.g., BAPI_VB41_CREATE). Import the BAPI structure into LTMOM. This
will define the fields available for migration.
o B. Defining a Custom Structure: If you're not using a BAPI, you would define your own custom
structure with the fields you need.
5. Define Source Structure: This describes the structure of your source data (e.g., from a CSV file, Excel sheet, or
legacy system). You'll need to map the fields in your source structure to the fields in the BAPI structure you
imported.
6. Define Target Structure: For BAPI-based objects, the target structure is usually the same as the BAPI structure
you imported.
7. Mapping: This is the most critical step. You need to map the fields from your source structure to the
corresponding fields in the BAPI structure. This tells LTMOM how to transfer the data. Pay close attention to
data types and formats.
8. Define Processing Rules (Optional): You can define processing rules to transform or validate data during the
migration. For example, you might need to convert data formats, handle errors, or perform lookups on other
SAP tables. ABAP code snippets can be used here.
9. BAPI Call: Specify the BAPI you'll be using to create or update the data in SAP (e.g., BAPI_VB41_CREATE).
LTMOM will use this BAPI to process the migrated data.
10. Generate Migration Object: Once you've defined the structure, mapping, and processing rules, generate the
migration object. This creates the necessary programs and structures for the migration.
11. Create a Migration Project in LTMC: Use transaction LTMC to create a new migration project.
❤ Like, 🎙 Comment, 📲 Repost and 🌡 Follow MICKAEL QUESNOT #SAP
https://www.linkedin.com/in/mickaelquesnot/ ©
1
12. Add Your Custom Migration Object to the Project: In your LTMC project, add the custom migration object you
created in LTMOM.
13. Upload Source Data: Upload your source data file (CSV, Excel, etc.) to the LTMC project.
14. Start the Migration: Execute the migration in LTMC. LTMOM will read the source data, apply the mapping and
processing rules, and call the BAPI to create the cross-selling data in SAP.
15. Monitor and Verify: Monitor the migration process in LTMC. Check the logs for any errors. After the migration,
verify the data in SAP to ensure it was migrated correctly.
• BAPI Functionality: Understand the BAPI you are using thoroughly. Know its input parameters, output
parameters, and any specific requirements.
• Error Handling: Implement proper error handling in your processing rules to catch any issues during the
BAPI call. The BAPI might return error messages that you need to handle.
• Testing: Test the migration thoroughly in a development or test system before migrating data to production.
• Performance: For large data volumes, consider optimizing the migration process. You might need to adjust
batch sizes or use parallel processing.
• Authorization: Ensure the user running the migration has the necessary authorizations to execute the BAPI
and create the data in SAP.
Example (Conceptual)
Let's say your source file has columns like "Sales Org," "Distribution Channel," "Product," "Cross-Selling Product," and
"Valid From Date." You would map these columns to the corresponding fields in the BAPI_VB41_CREATE structure.
During the migration, LTMOM would read each row from your source file, populate the BAPI structure, and call the
BAPI_VB41_CREATE function module to create the cross-selling record in SAP.
By following these steps, you can create custom migration objects in LTMOM to migrate data that isn't covered by
standard SAP migration objects. Remember to thoroughly test your migration object before using it in a production
environment. If you encounter any issues, consult with your SAP consultant.
SAP_BR_CONFIG_EXPERT_DATA_MIG
3
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
4
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
With this app, you can migrate business data to SAP S/4HANA. You can migrate data directly from certain SAP
source systems, or you can use staging tables to migrate data.
Key Features
Read more in
App Documentation
5
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
6
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
7
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
8
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
9
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
10
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
PREREQUISITES
Since S/4HANA 2020, SAP has deprecated LTMC using the web Dynpro version and moved to the Fiori app Migrate
Your Data (F3473).
we will use Function Module BAPI_SERVICE_CREATE to create a Service Master custom LTMC object.
1. Go to T-Code LTMOM
2. Choose the project that you want to create a new custom object.
11
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
12
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
13
3. After choosing the project, click in the menu bar Project->Create Migration Object->User-Defined->Migrate
Data Using Files/Staging Tables to create a new custom object
4. Enter the object ID and description and choose Function Module as the Target Structure, then click Next
15
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
16
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
17
5. Enter the name of Function Module, Return Parameter and TestRun parameter so that we can do the
simulation before uploading the data, then click continue
19
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
20
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
After successfully creating the new custom object, now we create a source structure.
6. Double click on the source structure at the left sidebar, right click on the source structure on the right sidebar,
then choose Append Structure to Lower Level.
21
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
22
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
23
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
24
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
8. Click add field to enter the fields of the source structure, then click the save
25
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
26
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
9. You can also make certain fields to become mandatory by right click the structure and then choosing change
view
27
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
28
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
29
STRUCTURE MAPPING
After creating the source structure, we map our source to the target structure.
31
12. Drag our source structure to the target mapping field, then click the save
33
FIELD MAPPING
And the last step is field mapping our source structure to the target structure.
14. Drag the source field to the target field just like we did in the previous step
15. Right click Single-Character Flag Number Range Check, then choose assign rule
16. Choose rule Move and enter parameter ‘X’ to assign a constant value to the field
35
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
36
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
37
TESTING
3. Our new custom migration object is automatically added to the project. Download the template
39
4. Complete the template data
41
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
42
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
43
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
44
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
45
6. Click Prepare
47
7. After the preparation of the staging table is completed, you can click instance to check your data.
49
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
50
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
51
9. If the simulation is successful, you can continue to migrate the data
53
MICKAEL QUESNOT © https://www.linkedin.com/in/mickaelquesnot/
SAP S/4HANA CONSULTANT / SAP HELPER
54
https://s4hclub.com/ © + https://www.youtube.com/@s4hclubforyou © All rights reserved
55
10. The migration data is successfully executed.
CONCLUSION
If pre-delivered LTMC objects don’t yet support your migration data requirements, you can create custom objects
using LTMOM with a standard or custom Function Module.
57