0% found this document useful (0 votes)
40 views6 pages

LSMW

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
40 views6 pages

LSMW

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

The LSMW (Legacy System Migration Workbench) is a tool provided by

SAP to migrate data from legacy systems into SAP. It’s often used during
the initial data migration phase of an SAP implementation project or for
occasional data uploads. It supports various methods to upload data
such as Batch Input, Direct Input, IDocs, and BAPIs.

Below is a step-by-step procedure for using LSMW in SAP from start to


finish:

---

1. Define Project, Subproject, and Object:


- T-Code: `LSMW`
- Go to LSMW transaction and define a Project, Subproject, and
Object:
- Project: Represents the migration task (e.g., "Customer_Migration").
- Subproject: Represents a sub-process within the project (e.g.,
"Customer_Master").
- Object: Represents the specific task to be done (e.g.,
"Customer_Data_Upload").

- Click on Create after filling in the Project, Subproject, and Object


fields.

---

2. Maintain Object Attributes:


- Select the created Project, Subproject, and Object, then click on
Execute.
- Specify the type of data migration method you want to use:
- Batch Input Recording: This is commonly used and is a simple way
to capture manual transactions.
- Standard Batch/Direct Input: For predefined standard upload
programs.
- BAPI or IDoc: For more advanced, real-time processing.

- After selecting the method, click on Save.


---

3. Maintain Source Structures:


- Define the structure of the source data being uploaded.
- Example: If you are uploading customer data, you would create
structures like:
- Header data (e.g., Customer ID, Name, Address)
- Bank details (e.g., Bank Account Number)

- Use the "Create" button to define your source structures.

---

4. Maintain Source Fields:


- Define the fields in the source structure that will be used for data
migration.
- Map fields from your source data file (such as Excel, CSV) to SAP
fields.
- Example: You may define fields like `Customer Number`, `Name`,
`Address`, etc.

- Click on the "Create" button for each field and define the respective
data type.

---

5. Maintain Structure Relations:


- In this step, map the source structures you just created to the SAP
structures.
- LSMW helps by suggesting SAP structures based on the object type.
Select the correct SAP structures and link them with the defined source
structure.


6. Maintain Field Mapping and Conversion Rules:
- This is the core part of LSMW, where you map the source fields (from
your file) to the corresponding SAP fields.
- For each field, you can define conversion rules (if needed), like
default values, fixed values, or data transformations.
- Example:
- Mapping `Source Field: Customer Name` to `SAP Field:
KNA1-NAME1`.
- You can also apply logic for data conversion (e.g., converting date
formats, applying default values, etc.).

- Standard Mapping Types:


- Constant: Set a constant value for a field.
- Translation: Map one value to another (e.g., "A" to "Active").
- Fixed Value: Assign a predefined value during migration.

---

7. Specify Files:
- Define the source file from which the data will be uploaded.
- Specify whether the file is local (PC) or application server (SAP
server).
- Select the file format (e.g., text file, CSV, Excel).

- Click on Assign Files and select the file that contains the source data.

---

8. Assign Files to Source Structures:


- Assign the uploaded file to the corresponding source structure
defined earlier.
- This helps SAP understand how to use the file for data migration.

- If multiple files are involved (e.g., customer and bank details), assign
them accordingly to their respective source structures.

---
9. Read Data:
- This step reads the data from the source file into SAP.
- Select Read Data from the LSMW main screen and click Execute.
- If successful, you will see how many records were read from the file.

- Check the log for any warnings or errors to ensure all data has been
read correctly.

---

10. Display Read Data (Optional):


- This step allows you to view the data that was read from the source
file to ensure that all records have been imported correctly.
- You can review the data before proceeding with further steps.

---

11. Convert Data:


- In this step, SAP converts the data from the source format into the
SAP format (based on the field mapping and conversion rules you
defined earlier).
- Click on Convert Data to start the conversion process.
- Check the log for any conversion errors or issues.

---

12. Display Converted Data (Optional):


- Review the converted data to ensure everything is mapped correctly.
- This helps you verify that the data will post correctly into SAP.

---
13. Create Batch Input Session:
- If using Batch Input Recording, create the Batch Input Session to
post the data.
- Select Create Batch Input Session, and SAP will generate a batch
input session for you.
- This session contains all the migrated data ready for processing.

- You can check the batch input session for any errors.

---

14. Run Batch Input Session:


- Go to Transaction Code: `SM35` to process the Batch Input Session.
- Select the session and click on Process to start posting the data into
SAP.
- You can run the session in Foreground (step-by-step) or Background
(automated) mode.
- If there are any errors, correct them, and reprocess the session.

---

15. Validate Data in SAP:


- After processing the Batch Input Session, validate the data posted in
SAP.
- Check tables, transactions, and reports to ensure the data has been
migrated correctly.

- Example: If customer master data was uploaded, you can verify it by


viewing the customer in `XD03`.

---

16. Cleanup and Documentation:


- After successful data migration, delete the Batch Input Session (from
`SM35`), especially if you processed the session in background mode.
- Document the entire LSMW process, including the field mappings,
conversion rules, and any issues that were resolved.
---

Best Practices:
- Data Validation: Always validate your source data before migration.
Ensure there are no duplicate or incorrect entries.
- Test Runs: Perform several test runs in a non-production environment
to ensure data is correctly migrated and mapped.
- Backup: Always have a backup of your source files before running any
migration.
- Reconciliation: After migration, reconcile the data between the legacy
system and SAP to ensure everything has been transferred correctly.

By following these steps, you can effectively use LSMW to upload


master data, transaction data, and other types of data into SAP during
an implementation project.

You might also like