Академический Документы
Профессиональный Документы
Культура Документы
Products
Products Industries
Industries Support
Support Training
Training Community
Community Developer
Developer Partner
Partner
About
About
Home / Community / Blogs + Actions
Sowmya Tiwary
more by this author
share
0 share
0 tweet share
0
Follow
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 1/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
many times the documentation does not exist and much effort is lost in trying
to understand and modify how the program works. So, LSMW seems an
easier solution as it does not take much effort to build one even from scratch.
This document shows steps to build a simple LSMW to upload assets where
the fields to be uploaded are standard.
Step 1: Create Project, Subproject and Object for the asset transfer. A project
or subproject already exisiting in the system could also be used to create the
object. For a scenario where we are migrating a company code from Legacy
to SAP, we could use the same project and subproject and create different
objects for uploading vendors, assets, customers etc.
Step 2: Enter the project, subproject and object name and click on execute.
Step 3: Click on the Maintain Object Attributes line and click on execute
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 2/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
There are 4 options through which data can be transferred through LSMW to
the SAP system:
In this document, we will use the Batch Input Recording method which is the
easiest according to me. In Batch input recording, we do a recording of AS91
transaction code for a sample asset filling in all fields which we would require
for our data transfer. Remember to fill only those fields which are required for
data transfer.
So, select the Batch Input Recording radio button and enter a name for the
recording. Once done, click the overview button next to the recording name
field.
On the overview screen, select the “create recording” button to start the
recording by giving a name and description.
On the next screen that appears, enter transaction code AS91. We will not use
transaction AS01 to create asset because we are creating a legacy asset.
Using AS91 will allow us to enter carry over values for asset from the legacy
system.
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 3/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 4/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
Create Source fields for the source structure. Source structure is the structure
of the file used to load data into SAP through LSMW
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 5/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
The above screenshot shows all the source fields in the source structure. The
excel or text file used to input data should have the same fields as defined in the
source structure and in the same order.
This step is used to map the source structure field from which the value is
input to every target structure field. All the target structure fields must be
mapped in this step. Click on the target structure field and use the Create
Source field button to assign
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 6/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
The input file is on the computer. Click on the “Legacy Data : On the PC” and
use the Add entry button to specify files.
The screen should already have the file specified in the previous step
assigned against the Source structure name
The below screenshot shows the sample file used. As can be seen, the fields
in the excel match the fields in the source structure. Since, we specified a text
file as the input file in Step 9, the below excel needs to be converted to a .txt
file before data can be uploaded.
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 7/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
This step reads the input file from the location specified. Generally, we read all
the rows from our input file. So, no transaction numbers are specified.
The whole file is read and as seen in the status below, 9 transactions have
been read.
In this step, all the records read from the input file are displayed.
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 8/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
Double click on a row to see the field values read against each of the fields in
the source structure.
Since we need all the records read from the input file to be converted to the
target structure, no transaction numbers are specified.
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 9/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
Double click on one of the rows to see the values as read into the target
structure fields and will be uploaded into SAP.
Specify the Name of the Batch session. Do not forget to select checkbox “Keep
batch input folder” so that logs for the batch input session can be analyzed once
the session processing is complete.
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 10/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
created in SAP and the asset numbers can be seen in the log for the batch
input session.
Alert Moderator
2 Comments
You must be Logged on to comment or reply to a post.
Nathan Genez
I’m curious, why would you use a recording? They are prone to error, inconsistent
(different screen layouts between asset classes), and tend to break down as time goes
on.
However, there are two delivered ABAP programs as well as a BAPI from SAP that are
superior options. The BAPI is faster, supported by SAP (a recording is not), has less
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 11/12
2/19/2018 Legacy System Asset Data Transfer using LSMW | SAP Blogs
setup time than a recording and much easier to administer… a recording uses a BDC
which is a painful way to deal with a large number of records as opposed to IDocs that
use WE02.
Everywhere I go, people still use recordings when there are BAPIs available. I’m
puzzled by this… why re-create a solution that SAP has already delivered?
Chongtuan Zhang
https://blogs.sap.com/2015/03/07/legacy-system-asset-data-transfer-using-lsmw/ 12/12