BDC DATA MIGRATION
BDC DATA MIGRATION
MIGRATION/CONVERSION
❖ What are the common steps involved in Data Migration/BDC?
➢ Common steps involved in Data Migration:-
■ Record the Screen Flow of the required functional T-code using the T-Code ‘SHDB’.
■ Convert the recorded screen Flow into a temporary program..
■ Upload the Flat file data from the Legacy System (Local PC /Al11) into an Internal
Table.
■ Convert the uploaded flat file data within the loop of the flat file internal table
(gt_flat_file).
■ Copy the system generated subroutines which start with BDC_DYNPRO& BDC-
FIELD from the temporary program & paste them within the loop of Flat file internal
table.
■ Comment screen default values & pass the flat file data.
■ Use any one of either session/call transaction to update/migrate the data.
■ Note: An icon export is used to download the recording into a local pc.
■ An icon read form file is used to generate a program using the given recording file.
❖ What is LSMW?
➢ Legacy System Migration Workbench.
➢ It is the system provided tool to migrate or convert the legacy system data.
➢ The T-Code 'LSMW' is used to work with this tool.
➢ An icon export is used to download the recording into Local PC.
➢ An option read from file is used to generate a program using the given recording file.\
❖ What are the steps for LSMW?
➢ There are a total of 14 steps in LSMW.
■ Maintain object attributes
■ Maintain source structures
■ Maintain source fields
■ Maintain structure relations
■ Maintain field mapping conversion rules
■ Maintain fixed values, translations & user-defined routines
■ Specify files
■ Assign files
■ Read data
■ Display read data
■ Convert data
■ Display converted data
■ Create batch input session
■ Run batch input session
❖ What are the differences between LSMW and BDC?
➢
LSMW BDC
Mostly used for both Huge & small BDC can be used for Small amount of
amount (Master) of data. data only.
LSMW is possible for custom screens / BDC can be used for custom
standards with custom fields of screens/custom fields of application
applications. also.
➢ SHDB: It is the T-code used to record the screen flow as the T-codes.
❖ What are the differences between Session Method and Call Transaction
Method?
➢
➢ Synchronous: In this mode, the data is not continuously updated in case of error
records. Asynchronous: It is used to update the data continuously by skipping the error
records.
❖ Is it possible to write an ABAP code in LSMW?
➢ Yes, by clicking on the change(pencil) icon that appears beside the recording structure
field.
❖ What are the Function Modules associated with the BDC Session Method?
➢ The System provided Functional Modules are
■ 'BDC_OPEN_GROUP ’: It is used to create the session using the T-code SM35.
■ 'BDC_INSERT’: It is used to insert the flat file data of the structure ‘BDCDATA’ with
transaction into session.
➢ Note: An export parameter “CTUPARMS” is used to handle the screen resolution in
case of table control to process the multiple line items in the session method.
➢ 'BDC_CLOSE_GROUP’: It is used to close the opened batch input session.
❖ How to handle messages in Call Transaction Method?
➢ Get the message details such as message type, message number into an internal
table (gt_bdcmsgcoll) of the type BDCMSGCOLL using an addition “….MESSAGES
INTO” with CALL TRANSACTION statement.
➢ Set a loop into an internal table (gt_bdcmsgcoll) of the type “bdcmsgcoll”.
➢ Use any of the function modules “FORAMT_MESSAGE”/”WRITE_MESSAGE” to get
the corresponding message text, since the structure “BDCMSGCOLL” does not have
any message text field.
➢ Display the populated messages with message text either list or ALV.
➢ Note: The standard table ‘T100’ can also be used to populate the message text.
❖ What is the syntax to make use of Call Transaction?
➢ CALL TRANSACTION '<T-CODE>' USING <gt_bdcdata> MODE <A/N/E>
UPDATE<S/A> MODE
<A/N/E> UPDATE <S/A> MESSAGES INTO <GT_BDCMSGCOLL>.
➢ Here <T-CODE> is the required transaction code through which the flat file data to be
migrated.
➢ <gt_bdcdata> is an internal table of type “bdc data” structure
➢ <A/N/E> are different data process modes
➢ A = All screens, N = No screens, E = Error screens
➢ <S/A> are the different update modes
❖ Which method do you prefer to migrate the data if the method is not
mentioned?
➢ CALL TRANSACTION.
❖ What are the fields in BDCMSGCOLL structure?
➢ BDCMSGCOLL is one structure in DDIC which contains the below fields
➢
Field Description
MSGID Message ID
Field Description