Professional Documents
Culture Documents
Sales Order Creation Using LSMW
Sales Order Creation Using LSMW
LSMW (Legacy System Migration Workbench) is a software-based SAP tool for single or
periodic data transfers from non-SAP to SAP. This transaction is often used during
cutover activities to upload master data like customer master, material master, condition
master, etc.
There are 4 types of methods to upload the data as part of the LSMW.
This document explains the steps to upload the sales orders using the “Standard
Batch/Direct Input method”.
STEPS
PROJECT CREATION
Execute the transaction LSMW, create a project and then click on execute button.
1
MAINTAIN OBJECT ATTRIBUTES
Select Maintain object attributes steps and then click on execute button.
2
MAINTAIN SOURCE STRUCTURES
Click on the create button and create the source structures as shown below.
You need to Create Item structure and partner structures under Header data.
3
You can also refer to the standard data structures for your reference.
To check the standard structure alignment, select Maintain source structure and click on
the Object Overview button.
4
MAINTAIN SOURCE FIELDS
Once the required source structures are created, select maintain source fields and click
on execute button.
NOTE: We must include the OLDNR field in all the source structures as it will be the
identifier/link between, Header, item, partner data, etc.
5
Maintain the required data load fields in each source structure and save the source
fields.
6
Select target structure and assign the source structure by clicking on the Relationship
button and then save the relationships.
Select maintain field mapping and conversion rules and click on execute button.
7
Select the target field, click on the source field button and then map the source field.
You can also use auto field mapping if the source and target field names are the same.
8
NOTE: While using the LSMW, there would be issues in converting the source field value
to target field.
In order to avoid such issues, We need to convert the source field value into the required
format of sales order creation or we need to implement conversion logic for the required
fields.
For example, There is a customer code 10000 in the source field which is not accepted
while creating the sales order using LSMW as the leading zeros are missing. In this case,
the system needs customer code in the 10 digit format with remaining leading zeros
“0000010000”.
For this, you can make use of the function module to convert the customer code into
required format under this step.
9
Implement the conversion logic and any other validations before data conversion.
SPECIFY FILES
10
Before this, We need to prepare an excel sheet with the Header data, Item data and
Partner data as per our source structure fields.
Then copy the data from the excel sheet and prepare three different Text files. I.e.,
Header data, Item data and Partner data.
11
Once the Text files are created as per the defined structures, Select Legacy data on the PC
and click on Add entry button.
12
Select the files, choose Tabular radio button, choose ASCII button under Code page and
then press enter. Repeat the same for all the data files.
Under converted data, Logical file and Logical path must be maintained.
13
FINDING LOGICAL FILE
In order to find the Logical file name, go to the first steps “Maintain object attributes”,
click on the display button beside the program name.
Go to the transaction FILE, and find the Logical file name under the below node and then
14
click on Details button.
As shown in the below screenshot, Logical file name and Logical path needs to be
mapped in the previous step and the converted file name should be maintained under
the physical file field. Data format should be ASC as selected while specifying the data
files and the application area should be SD.
15
Copy the Logical path from the above step and double click on Logical file path
definition.
Select the Logical file path and couple click on Assignment of Physical paths.
Click on New entries and add the Syntax group and Physical path.
Syntax groups are most probably similar to Operating systems which you can find from
System→Status.
16
ASSIGN FILES
Select source structure, click on assign files and assign the relevant file to it.
17
READ DATA
18
CONVERT DATA
19
DISPLAY CONVERTED DATA
Cross check the converted data before attempting further steps and correct it necessary.
Select start direct input program and select either program or transaction option.
20
PROGRAM RVINVB10
21
This can be cross checked in the VA03 transaction.
22
Click on the Define Job button.
Click on new entries, enter the Job name, Program name and Variant name. Click on
Maintain variants.
23
Click on the create button.
Enter the description, activate Only background processing and save it.
24
JOB CREATION USING BMV0
25
A job entry will be created as shown in the below screenshot. You can also click on the
update button if a bulk upload is under process.
Select the Job name and click on the Job log button to check the sales order creation
status.
26
You can find the job log status with the created sales orders.
THANK YOU
27