The Best Ways to Utilize LSMW in 14 steps

Spread the love

Introduction

We have often encountered challenges to migrate mass upload of master records in SAP during our implementation journey. Today will try to explain how come over such an issue with using SAP standard tools. LSMW (Legacy System Migration Workbench) is a software-based SAP tool for single or periodic transfers of data from non-SAP to SAP (as restricted from SAP to SAP) systems (and with restriction from SAP to SAP system).

Its core functions are: Importing legacy data from PC spreadsheet tables or sequential files.LSMW can be used across the SAP Module such as SAP SD, SAP MM.

What is Data migration?

The data from the legacy system must be transferred into the Non SAP System to implement SAP R/3 system . It is also necessary to regularly move the data from Trading Legacy system to R/3 system (interfacing).

At the end of the R/3 implementation, data migration comes into picture where all master data , Transactional data needs to transfer into Newly configure SAP System .The first configuration should be completed & move to production then we to begin with data migration Activity . In this phased we will move all master data to SAP system before system is Operational for user .

Data migration is very significance steps for any successful SAP Implementation .The migration of data is approximately 20% to 40% of total implementation costs.

There are two tools we often use to migrate data

  • BDC (Batch Data Communication)
  • LSMW (Legacy System Migration Workbench)

Todays we will be focusing only on LSMW . Lets get started

What is the LSMW?

LSMW stands for Legacy System Migration Workbench . The LSMW Workbench is an R/3-based tool that allows us to transfer data once or regularly from Non-SAP Systems to R/3.Its very simple & easy to use tool which make mass data migration in a few simple steps .Data imports into R/3 should be better quality and consistency than data immigration speed and performance.

How LSMW works in sap ?

The LSMW main functions are:

  • Import data ( legacy data in MS excel or text format sequential file)
  • Conversion of data (from source format to target format)
  • Import the data into the application R/3 database

Advantages of LSMW

  • Advantage of LSMW import to be used in each case is defined by the business object as well as the availability of standard input programmes.
  • R/3 is integrated, making it independent of individual platforms.
  • Consistency of the data by standard methods use for import
    • Batch Inputs
    • Direct Inputs
    • BAPI (Business Application Programming Interfaces)
    • IDOC(Intermediate Documents)
  • Existing skills and coding be utilised.

Types of LSMW in sap

The LSMW tool offers four different upload options. lets understand what is advantages & disadvantages

Batch Input:

  • Advantages: Easy to modify, all fields are accessible, and reprocessing is quick.
  • Disadvantages: Relatively slow; to use new screens or tabs, a new recording must be created; not easily available for enjoy transactions; differences in foreground and background processing can occur depending on user settings.

Standard/Direct Input

  • Advantages: Well-proven mehtood , quick loading, and simple processing.
  • Disadvantages: There are no enjoy transactions, and transactions are not always completed with all input fields.

BAPI’s

  • Advantages: Quick to load, simple to process, and logical interface for functional/end users focused on business processes. on the contrary to common opinion, there are a range of drawbacks to using this form.
  • Disadvantages:Not all transaction input fields are always completed

IDOCs

  • Advantages :Fast loading, simple processing, and low programming for standard IDOCs
  • Disadvantages:Knowledge of IDOC processing is needed, and making changes to a previously generated IDOC can be time consuming.

Difference between BDC & LSMW ?

  • Direct input, BAPI, Idoc, and batch input recording are some of the data migration techniques offered by LSMW where as on the other hand, BDC primarily employs batch input sessions and the CALL TRANSACTION process.
  • There is a limit to the amount of records that can be submitted in a single BDC session (999 records). In LSMW, there is no such restriction.
  • LSMW is more concerned with setup, while BDC is more concerned with programming.

How many steps are there in Lsmw?

LSMW contains 14 essential steps in addition to project/subproject/object creation and recording.

What are the steps to create new LSMW in SAP | How do you use LSMW?

Here’s an example of how to use the LSMW conversion method in SAP. Since LSMW is an extra transaction, it is not available in the regular SAP menu. Enter the transaction code LSMW.

In this example , We will create customer master records using LSMW

Every conversion activity is organised into Projects, Subprojects, and Objects.Here we needs to define Project, Subproject & Objects

Legacy System Migration Workbench
Legacy System Migration Workbench

The main screen of LSMW offers wizard-like step-by-step activities.We must complete these steps in order to complete our data conversion. The cursor is automatically moved to the next step after each step is completed.

how to create lsmw in sap with screenshots
how to create lsmw in sap with screenshots

Step 1: Maintain Object Attributes

In this example , We will create new customer in SAP hence we will be updating the customer master records with transaction in this case (XD01). To record the R/3 transaction, select the radio button Batch Input Recording as we are going to use simple recording methods and press the recording summary icon. Enter XD01 REC as the recording name, Customer Master Create Recording as the summary, and XD01 as the transaction code.

Alternative , we many used other methods

lsmw tutorials
lsmw methods in sap

The system calls XD01 to Create customer change transaction as shown below

lsmw for customer master
Customer Master Initials screen

Specify mandatory key fields for customer creation . In this case we have specify account group ,name salutation, Customer Name & Search term for creation customer master .Once recording completed R/3 logs the flow of screens and fields and saves information .Default values are set when the transaction was recorded.

Note that field names are stored in a technical format by the transaction recording process. The system displays technical names by pressing the F1 key on each screen and then pressing the F9 key. Then you can substitute descriptive names for technical names.

lsmw recording
LSMW Transaction recording overview

Step 2. Maintain Source Structures

Give the source structure a name and description

lsmw change source structures
LSMW Maintain Source Structures

Step 3. Maintain Source Fields

In this step, the fields in the source structure must be listed. The easiest way to enter field names, types and lengths for each field is by clicking on the ‘Maintenance Table’ icon

LSMW Maintain Source Fields
LSMW Maintain Source Fields

Use field names with the same names as the target field names, since in the step 5 ‘Maintain field mapping and conversion rules,’ you can use the function ‘auto-field mapping.

Step 4: Maintain Structure Relations

Execute a ‘Structure Relations Maintain’ step. . The relationship automatically defaults, because there is only one Source/Target structure.

LSMW Maintain Structure Relations
LSMW Maintain Structure Relations

Step 5: Maintain fields mapping & Conversion rules

Use the auto fields mapping to Maintain fields mapping & conversion rules.

LSMW Maintain field mapping and conversion rules
LSMW Maintain field mapping and conversion rules

Step 6: Maintain fixed values, translations, User defined routines for LSMW

We can also reuse user-defined routines and reusable translations that can be used for transformation tasks. This step is not necessary in this case.

LSMW Maintain fixed values, translations, user-defined routines
LSMW Maintain fixed values, translations, user-defined routines

Step 7: Specify the local files

We needs specify how the input file is layout in this step. The input file is a with field names in the first row. It’s available as C:\Users \test\1.txt on my pc (local disc).

LSMW Specify the local files
LSMW Specify the local files

Here we have specify Tab delimited file format

lsmw data format
lsmw data format

Step 8: Assign files

Perform the Assign Files step as below and the system defaults to the source structure by the filename automatically.

LSMW Assign files
LSMW Assign files

Step 9: Read data

In this Steps ,LSMW reads the data from the source file (from the local PC drive).& read and convert selected rows into internal format data values.

LSMW Read data
LSMW Read data

Step 10: Display read data

It is an optional step. If necessary, the field contents for the read data rows can be reviewed.

LSMW Display read data
LSMW Display read data

Step 11: Convert data

This is the step by which the source data (in source format) is actually converted into a target format. The source fields are mapped to the target areas on the basis of the conversion rules defined.

LSMW Convert data
LSMW Convert data

Step 12: Display Converted data

This is another optional step to see how the source data is transformed into internal SAP format

Step 13: Create batch input session

We can create a batch session to process updates when the source data is converted to an internal format.

LSMW  Create batch input session
LSMW Create batch input session

Step 14: Run Batch Input Session

Run batch input session allows us to execute the BDC session. A standard SM35 transaction for BDC session management is the performance of a batch input session. The client master logs are updated on the system once you have successfully completed the batch entry session. By viewing the client masters records, you can confirm this (XD01).

LSMW Run Batch Input Session
LSMW Run Batch Input Session

Now it is recommended to validated your changes in the SAP System before you perform mass data upload. Alternatively, you may use LSMW in your Quality system. If everything working correctly, then use the same lsmw in your Production system

How do you import and export Lsmw in SAP?

It’s very easy to move LSMW from one server to any other server using export and import functionally of any project/object. Choose the objects you want to Export -import. The system automatically downloads the mapping rule in a text format file by clicking on the Export Project.

export Lsmw in SAP
Export Lsmw in SAP

Similarly, In the target server, you need to upload the exiting project /object mapping rule using the import functionality

Import Lsmw in SAP
Import Lsmw in SAP

Is it possible to use Lsmw in S/4 Hana?


In S/4 Hana SAP provides predefined migration objects you can use. Migration is done with LTMC – the tool (Legacy Transfer Migration Cockpit) The SAP S/4HANA migration cockpit can be accessed through LTMC transaction.

Legacy Transfer Migration Cockpit-
Legacy Transfer Migration Cockpit

Hope this article helps you to explore how to leverage LSMW, Data migration tools. Here are a couple of other articles that you check

Leave a Reply

error

Enjoy this blog? Please spread the word :)

%d bloggers like this: