<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: create material master data in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/create-material-master-data/m-p/2867227#M672656</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Transaction Recorder (SHDB) &lt;/P&gt;&lt;P&gt;How to Upload Presentation Server Flat file to SAP R/3 system???&lt;/P&gt;&lt;P&gt;How to upload application server file to R/3 system?&lt;/P&gt;&lt;P&gt;Definition&lt;/P&gt;&lt;P&gt;Example - Call Transaction Method &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Transaction Recorder (SHDB)&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Before you work with the Batch Input methods, you should know the purpose of the tool&lt;/P&gt;&lt;P&gt;Transaction Recorder.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use:&lt;/P&gt;&lt;P&gt;You can use the transaction recorder to record a series of transactions and their screens.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Features:&lt;/P&gt;&lt;P&gt;You can use the recording to create&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Data transfer programs that use batch input or CALL TRANSACTION &lt;/P&gt;&lt;P&gt;Batch input sessions &lt;/P&gt;&lt;P&gt;Test data &lt;/P&gt;&lt;P&gt;Function modules.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note: It doesn&amp;#146;t record F1, F4 and Scrollbar movements&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Upload Flat file from Presentation Server to SAP R/3&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION &amp;#145;GUI_UPLOAD'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;CODEPAGE = &amp;#145;IBM'&lt;/P&gt;&lt;P&gt;FILENAME = P_UFILE&lt;/P&gt;&lt;P&gt;FILETYPE = 'DAT'&lt;/P&gt;&lt;P&gt;TABLES&lt;/P&gt;&lt;P&gt;DATA_TAB = INT_TAB&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;CONVERSION_ERROR = 1&lt;/P&gt;&lt;P&gt;FILE_OPEN_ERROR = 2&lt;/P&gt;&lt;P&gt;FILE_READ_ERROR = 3&lt;/P&gt;&lt;P&gt;INVALID_TYPE = 4&lt;/P&gt;&lt;P&gt;NO_BATCH = 5&lt;/P&gt;&lt;P&gt;UNKNOWN_ERROR = 6&lt;/P&gt;&lt;P&gt;INVALID_TABLE_WIDTH = 7&lt;/P&gt;&lt;P&gt;GUI_REFUSE_FILETRANSFER = 8&lt;/P&gt;&lt;P&gt;CUSTOMER_ERROR = 9&lt;/P&gt;&lt;P&gt;OTHERS = 10 .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF SY-SUBRC NE 0.&lt;/P&gt;&lt;P&gt;MESSAGE E999(FR) WITH 'ERROR IN FILE UPLOAD'.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Upload file from application server to SAP R/3&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Open the the application server file &lt;/P&gt;&lt;P&gt;OPEN DATASET &amp;lt;dsn&amp;gt; FOR INPUT &amp;lt;mode&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Read the data from application server file&lt;/P&gt;&lt;P&gt;READ DATASET &amp;lt;dsn&amp;gt; INTO &amp;lt;wa&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And then close the application server file&lt;/P&gt;&lt;P&gt;CLOSE DATASET &amp;lt;dsn&amp;gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Definition- Declaring BDC Table &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BDC_TAB LIKE STANDARD TABLE OF &lt;/P&gt;&lt;P&gt;BDCDATA INITIAL SIZE 6 &lt;/P&gt;&lt;P&gt;WITH HEADER LINE .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The internal table used to collect the transaction&amp;#146;s information must be declared &amp;#147;LIKE BDCDATA&amp;#148;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Filling BDC Table &amp;#150; Method #1&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM FILL_BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REFRESH BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-PROGRAM = &amp;#145;SAPMF02K&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNPRO = &amp;#145;01016&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNBEGIN = &amp;#145;X&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-FNAM = &amp;#145;RF02K-LIFNR&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-FVAL = &amp;#145;TEST1&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-FNAM = &amp;#145;RF02K-D0010&amp;#146;. &lt;/P&gt;&lt;P&gt;BDC_TAB-FVAL = &amp;#145;X&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-PROGRAM = &amp;#145;SAPMF02K&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNPRO = &amp;#145;0110&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNBEGIN = &amp;#145;X&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-FNAM = &amp;#145;LFA1-STRAS&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-FVAL = &amp;#145;123 Main St.&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-FNAM = &amp;#145;BDC_OKCODE&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-FVAL = &amp;#145;/11&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Filling BDC Table &amp;#150; Method #2&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM FILL_BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REFRESH BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PERFORM POPULATE_BDC_TAB&lt;/P&gt;&lt;P&gt;USING:&lt;/P&gt;&lt;P&gt;&amp;#145;1&amp;#146; &amp;#145;SAPMF02K&amp;#146; &amp;#145;0106&amp;#146;,&lt;/P&gt;&lt;P&gt;&amp;#145; &amp;#145; &amp;#145;RF02K-LIFNR&amp;#146; &amp;#145;TEST1&amp;#146;,&lt;/P&gt;&lt;P&gt;&amp;#145; &amp;#145; &amp;#145;RF02K-D0010&amp;#146; &amp;#145;X&amp;#146;,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;#145;1&amp;#146; &amp;#145;SAPMF02K&amp;#146; &amp;#145;0110&amp;#146;,&lt;/P&gt;&lt;P&gt;&amp;#145; &amp;#145; &amp;#145;LFA1-STRAS&amp;#146;, &amp;#145;123 Main St.&amp;#146;,&lt;/P&gt;&lt;P&gt;&amp;#145; &amp;#145; &amp;#145;BDC_OKCODE&amp;#146;, &amp;#145;/11&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM POPULATE_BDC_TAB USING FLAG VAR1 VAR2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;IF FLAG = &amp;#145;1&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-PROGRAM = VAR1.&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNPRO = VAR2..&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNBEGIN = &amp;#145;X&amp;#146;.&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;BDC_TAB-FNAM = VAR1.&lt;/P&gt;&lt;P&gt;BDC_TAB-FVAL = VAR2.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This two subroutine method to fill the BDC table is preferable because the &amp;#147;POPULATE_BDC_TABLE&amp;#148; subroutine is reusable throughout all batch input programs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Example #1 - Change Vendor (Call Transaction Method)&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Example #1- Declaration Section&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT Y180DM10.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BDC_TAB LIKE STANDARD TABLE OF&lt;/P&gt;&lt;P&gt;BDCDATA INITIAL SIZE 6 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;INFILE(20) VALUE &amp;#145;/tmp/bc180_file4&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF INREC.&lt;/P&gt;&lt;P&gt;VENDNUM LIKE LFA1-LIFNR.&lt;/P&gt;&lt;P&gt;STREET LIKE LFA1-STRAS.&lt;/P&gt;&lt;P&gt;END OF INREC.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PARAMETERS: DISPMODE DEFAULT &amp;#145;A&amp;#146;,&lt;/P&gt;&lt;P&gt;UPDAMODE DEFAULT &amp;#145;S&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;OPEN DATASET INFILE&lt;/P&gt;&lt;P&gt;FOR INPUT IN TEXT MODE.&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;READ DATASET INFILE INTO INREC.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt; &amp;gt; 0. EXIT. ENDIF.&lt;/P&gt;&lt;P&gt;PERFORM FILL_BDC_TAB.&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;FK02&amp;#146;&lt;/P&gt;&lt;P&gt;USING BDC_TAB&lt;/P&gt;&lt;P&gt;MODE DISPMODE&lt;/P&gt;&lt;P&gt;UPDATE UPDAMODE.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt; &amp;gt; 0.&lt;/P&gt;&lt;P&gt;WRITE: /&amp;#145;ERROR&amp;#146;. &lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;CLOSE DATASET INFILE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;synchronous updating&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;&amp;#133;&amp;#133;&amp;#133;&lt;/P&gt;&lt;P&gt;PERFORM FILL_BDC_TAB.&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;FK02&amp;#146;&lt;/P&gt;&lt;P&gt;USING BDC_TAB&lt;/P&gt;&lt;P&gt;MODE &amp;#145;N&amp;#146;&lt;/P&gt;&lt;P&gt;UPDATE &amp;#145;S&amp;#146;.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt; &amp;gt; 0.&lt;/P&gt;&lt;P&gt;WRITE: /&amp;#145;ERROR&amp;#146;. &lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With synchronous updating, we can check SY-SUBRC to determine the success of the transaction and the actual update to the database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;asynchronous updating&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;&amp;#133;&amp;#133;&amp;#133;&lt;/P&gt;&lt;P&gt;PERFORM FILL_BDC_TAB.&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;FK02&amp;#146;&lt;/P&gt;&lt;P&gt;USING BDC_TAB&lt;/P&gt;&lt;P&gt;MODE &amp;#145;N&amp;#146;&lt;/P&gt;&lt;P&gt;UPDATE &amp;#145;A&amp;#146;.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt; &amp;gt; 0.&lt;/P&gt;&lt;P&gt;WRITE: /&amp;#145;ERROR&amp;#146;. &lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With asynchronous updating, we can check SY-SUBRC to determine the success of the transaction only, not the actual update to the database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Error Handling&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Write an error report.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Send the record(s) in error to an error file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Create a batch input session with the record(s) in error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To store error messages ( CALL TRANSACTION )&lt;/P&gt;&lt;P&gt;data: begin of Tab_Mess occurs 0.&lt;/P&gt;&lt;P&gt;include structure bdcmsgcoll.&lt;/P&gt;&lt;P&gt;data : end of Tab_Mess,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;FK02&amp;#146; USING BDC_TAB MODE &amp;#145;N&amp;#146; UPDATE &amp;#145;S&amp;#146; &lt;/P&gt;&lt;P&gt;MESSAGES INTO TAB_MESS.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC NE 0.&lt;/P&gt;&lt;P&gt;WRITE: / Tab_MESS-TCODE, Tab_MESS-DYNUMB, Tab_MESS-MSGTYP , &lt;/P&gt;&lt;P&gt;Tab_MESS-MSGID.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;i am giving you example for Change Vendor you practice for ur tcode&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For our example, we will use the &amp;#147;Change Vendor&amp;#148; transaction (&amp;#147;FK02&amp;#148;) to add a street address to an already existing vendor.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #1&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Use &amp;#147;System&amp;amp;#61664;Status&amp;#148; menu path to determine online program name (SAPMF02K), screen number (0110)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #2&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Use &amp;#147;F1&amp;#148; key and &amp;#147;Technical Info&amp;#148; pushbutton in each screen field to be filled to determine the field name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #3&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;Determine how to proceed in the transaction&lt;/P&gt;&lt;P&gt;(save the record by clicking on the &amp;#145;Save&amp;#146; pushbutton or pressing the &amp;#145;F11&amp;#146; key).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;BDC Table Contents&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;After researching the transaction we can determine the contents of the BDC table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PROGRAM DYNPRO DYNBEGIN FNAM FVAL&lt;/P&gt;&lt;P&gt;SAMPF02K 0106 X &lt;/P&gt;&lt;P&gt;RF02K-LIFNR TEST1&lt;/P&gt;&lt;P&gt;RF02K-D0110 X&lt;/P&gt;&lt;P&gt;SAMPF02K 0110 X &lt;/P&gt;&lt;P&gt;LFA1-STRAS 123 Main St.&lt;/P&gt;&lt;P&gt;BDC_OKCODE /11&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Batch Input Methods&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;#147;CALL TRANSACTION USING&amp;#148;&lt;/P&gt;&lt;P&gt;STATEMENT&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Call transaction - for data transfer&lt;/P&gt;&lt;P&gt;Processing batch input data with CALL TRANSACTION USING is the faster of the two recommended data transfer methods. In this method, legacy data is processed inline in your data transfer program. &lt;/P&gt;&lt;P&gt;Syntax:&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;lt;tcode&amp;gt;&lt;/P&gt;&lt;P&gt;USING &amp;lt;bdc_tab&amp;gt;&lt;/P&gt;&lt;P&gt;MODE &amp;lt;mode&amp;gt;&lt;/P&gt;&lt;P&gt;UPDATE &amp;lt;update&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A Display all&lt;/P&gt;&lt;P&gt;E Display errors only&lt;/P&gt;&lt;P&gt;N No display&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;S Synchronous&lt;/P&gt;&lt;P&gt;A Asynchronous&lt;/P&gt;&lt;P&gt;L Local update&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;The process flow of CALL TRANSACTION&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A program that uses CALL TRANSACTION USING to process legacy data should execute thefollowing steps:&lt;/P&gt;&lt;P&gt;Prepare a BDCDATA structure for the transaction that you wish to run. &lt;/P&gt;&lt;P&gt;Prepare a internal table to store error messages Tab_Mess like structure of BDCMSGCOLL.&lt;/P&gt;&lt;P&gt;With a CALL TRANSACTION USING statement, call the transaction and prepare the BDCDATA structure. For example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;MM01' USING BDCDATA MODE 'A' UPDATE 'S'. MESSAGES INTO TAB_MESS.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;&amp;lt;Error_handling&amp;gt;.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Overview of Batch Input Session&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The first batch input method is to create a batch input session. It is the processing of this batch input session that updates the database, not the execution of the batch input program. i am giving you example for Change Vendor you practice for ur tcode &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For our example, we will use the &amp;#147;Change Vendor&amp;#148; transaction (&amp;#147;FK02&amp;#148;) to add a street address to an already existing vendor.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #1&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Use &amp;#147;System&amp;amp;#61664;Status&amp;#148; menu path to determine online program name (SAPMF02K), screen number (0110)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #2&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Use &amp;#147;F1&amp;#148; key and &amp;#147;Technical Info&amp;#148; pushbutton in each screen field to be filled to determine the field name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #3&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;Determine how to proceed in the transaction&lt;/P&gt;&lt;P&gt;(save the record by clicking on the &amp;#145;Save&amp;#146; pushbutton or pressing the &amp;#145;F11&amp;#146; key).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;BDC Table Contents&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;After researching the transaction we can determine the contents of the BDC table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PROGRAM DYNPRO DYNBEGIN FNAM FVAL&lt;/P&gt;&lt;P&gt;SAMPF02K 0106 X &lt;/P&gt;&lt;P&gt;RF02K-LIFNR TEST1&lt;/P&gt;&lt;P&gt;RF02K-D0110 X&lt;/P&gt;&lt;P&gt;SAMPF02K 0110 X &lt;/P&gt;&lt;P&gt;LFA1-STRAS 123 Main St.&lt;/P&gt;&lt;P&gt;BDC_OKCODE /11&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Batch Input Methods&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;#147;CALL TRANSACTION USING&amp;#148;&lt;/P&gt;&lt;P&gt;STATEMENT&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Call transaction - for data transfer&lt;/P&gt;&lt;P&gt;Processing batch input data with CALL TRANSACTION USING is the faster of the two recommended data transfer methods. In this method, legacy data is processed inline in your data transfer program. &lt;/P&gt;&lt;P&gt;Syntax:&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;lt;tcode&amp;gt;&lt;/P&gt;&lt;P&gt;USING &amp;lt;bdc_tab&amp;gt;&lt;/P&gt;&lt;P&gt;MODE &amp;lt;mode&amp;gt;&lt;/P&gt;&lt;P&gt;UPDATE &amp;lt;update&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A Display all&lt;/P&gt;&lt;P&gt;E Display errors only&lt;/P&gt;&lt;P&gt;N No display&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;S Synchronous&lt;/P&gt;&lt;P&gt;A Asynchronous&lt;/P&gt;&lt;P&gt;L Local update&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;The process flow of CALL TRANSACTION&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A program that uses CALL TRANSACTION USING to process legacy data should execute thefollowing steps:&lt;/P&gt;&lt;P&gt;Prepare a BDCDATA structure for the transaction that you wish to run. &lt;/P&gt;&lt;P&gt;Prepare a internal table to store error messages Tab_Mess like structure of BDCMSGCOLL.&lt;/P&gt;&lt;P&gt;With a CALL TRANSACTION USING statement, call the transaction and prepare the BDCDATA structure. For example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;MM01' USING BDCDATA MODE 'A' UPDATE 'S'. MESSAGES INTO TAB_MESS.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;&amp;lt;Error_handling&amp;gt;.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Overview of Batch Input Session&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The first batch input method is to create a batch input session. It is the processing of this batch input session that updates the database, not the execution of the batch input program. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Reward if usefull&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 05 Oct 2007 07:01:48 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-10-05T07:01:48Z</dc:date>
    <item>
      <title>create material master data</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/create-material-master-data/m-p/2867224#M672653</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear sir,&lt;/P&gt;&lt;P&gt;  how to create a material data using mm01.&lt;/P&gt;&lt;P&gt;explain step by step procdure..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Oct 2007 04:05:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/create-material-master-data/m-p/2867224#M672653</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-05T04:05:12Z</dc:date>
    </item>
    <item>
      <title>Re: create material master data</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/create-material-master-data/m-p/2867225#M672654</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Goto Mm01&lt;/P&gt;&lt;P&gt;enter Material Type (finished Goods, trading goods etc) and industry sector(chemical,manufacturingetc) from the drop down select something&lt;/P&gt;&lt;P&gt;then enter or select views&lt;/P&gt;&lt;P&gt;select few views&lt;/P&gt;&lt;P&gt;depending on the views you need to enter the parameters like Plant storage location, sales orgn, dist channel etc&lt;/P&gt;&lt;P&gt;see them in the F4 list and select one&lt;/P&gt;&lt;P&gt;and enter the manadatory fields like description, unit of measure  and other fields in each screen and Save the data&lt;/P&gt;&lt;P&gt;check in MARA and MARC tables whether the data is saved or not&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Anji&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Oct 2007 04:47:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/create-material-master-data/m-p/2867225#M672654</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-05T04:47:25Z</dc:date>
    </item>
    <item>
      <title>Re: create material master data</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/create-material-master-data/m-p/2867226#M672655</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;here we can post screen shots..please search in WIKI of SDN or Google&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;it better..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also please try to see a material which is already existing in MM03 and u can replicate the field values in MM01..u can find already existing material in se11&lt;/P&gt;&lt;P&gt;put MARA in table name and then see table entries by pressing a matrix  button in toolbar...&lt;/P&gt;&lt;P&gt;If you like this idea reward points..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Oct 2007 06:35:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/create-material-master-data/m-p/2867226#M672655</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-05T06:35:14Z</dc:date>
    </item>
    <item>
      <title>Re: create material master data</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/create-material-master-data/m-p/2867227#M672656</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Transaction Recorder (SHDB) &lt;/P&gt;&lt;P&gt;How to Upload Presentation Server Flat file to SAP R/3 system???&lt;/P&gt;&lt;P&gt;How to upload application server file to R/3 system?&lt;/P&gt;&lt;P&gt;Definition&lt;/P&gt;&lt;P&gt;Example - Call Transaction Method &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Transaction Recorder (SHDB)&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Before you work with the Batch Input methods, you should know the purpose of the tool&lt;/P&gt;&lt;P&gt;Transaction Recorder.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use:&lt;/P&gt;&lt;P&gt;You can use the transaction recorder to record a series of transactions and their screens.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Features:&lt;/P&gt;&lt;P&gt;You can use the recording to create&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Data transfer programs that use batch input or CALL TRANSACTION &lt;/P&gt;&lt;P&gt;Batch input sessions &lt;/P&gt;&lt;P&gt;Test data &lt;/P&gt;&lt;P&gt;Function modules.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note: It doesn&amp;#146;t record F1, F4 and Scrollbar movements&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Upload Flat file from Presentation Server to SAP R/3&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION &amp;#145;GUI_UPLOAD'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;CODEPAGE = &amp;#145;IBM'&lt;/P&gt;&lt;P&gt;FILENAME = P_UFILE&lt;/P&gt;&lt;P&gt;FILETYPE = 'DAT'&lt;/P&gt;&lt;P&gt;TABLES&lt;/P&gt;&lt;P&gt;DATA_TAB = INT_TAB&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;CONVERSION_ERROR = 1&lt;/P&gt;&lt;P&gt;FILE_OPEN_ERROR = 2&lt;/P&gt;&lt;P&gt;FILE_READ_ERROR = 3&lt;/P&gt;&lt;P&gt;INVALID_TYPE = 4&lt;/P&gt;&lt;P&gt;NO_BATCH = 5&lt;/P&gt;&lt;P&gt;UNKNOWN_ERROR = 6&lt;/P&gt;&lt;P&gt;INVALID_TABLE_WIDTH = 7&lt;/P&gt;&lt;P&gt;GUI_REFUSE_FILETRANSFER = 8&lt;/P&gt;&lt;P&gt;CUSTOMER_ERROR = 9&lt;/P&gt;&lt;P&gt;OTHERS = 10 .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF SY-SUBRC NE 0.&lt;/P&gt;&lt;P&gt;MESSAGE E999(FR) WITH 'ERROR IN FILE UPLOAD'.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Upload file from application server to SAP R/3&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Open the the application server file &lt;/P&gt;&lt;P&gt;OPEN DATASET &amp;lt;dsn&amp;gt; FOR INPUT &amp;lt;mode&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Read the data from application server file&lt;/P&gt;&lt;P&gt;READ DATASET &amp;lt;dsn&amp;gt; INTO &amp;lt;wa&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And then close the application server file&lt;/P&gt;&lt;P&gt;CLOSE DATASET &amp;lt;dsn&amp;gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Definition- Declaring BDC Table &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BDC_TAB LIKE STANDARD TABLE OF &lt;/P&gt;&lt;P&gt;BDCDATA INITIAL SIZE 6 &lt;/P&gt;&lt;P&gt;WITH HEADER LINE .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The internal table used to collect the transaction&amp;#146;s information must be declared &amp;#147;LIKE BDCDATA&amp;#148;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Filling BDC Table &amp;#150; Method #1&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM FILL_BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REFRESH BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-PROGRAM = &amp;#145;SAPMF02K&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNPRO = &amp;#145;01016&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNBEGIN = &amp;#145;X&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-FNAM = &amp;#145;RF02K-LIFNR&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-FVAL = &amp;#145;TEST1&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-FNAM = &amp;#145;RF02K-D0010&amp;#146;. &lt;/P&gt;&lt;P&gt;BDC_TAB-FVAL = &amp;#145;X&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-PROGRAM = &amp;#145;SAPMF02K&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNPRO = &amp;#145;0110&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNBEGIN = &amp;#145;X&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-FNAM = &amp;#145;LFA1-STRAS&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-FVAL = &amp;#145;123 Main St.&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;BDC_TAB-FNAM = &amp;#145;BDC_OKCODE&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-FVAL = &amp;#145;/11&amp;#146;.&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Filling BDC Table &amp;#150; Method #2&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM FILL_BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REFRESH BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PERFORM POPULATE_BDC_TAB&lt;/P&gt;&lt;P&gt;USING:&lt;/P&gt;&lt;P&gt;&amp;#145;1&amp;#146; &amp;#145;SAPMF02K&amp;#146; &amp;#145;0106&amp;#146;,&lt;/P&gt;&lt;P&gt;&amp;#145; &amp;#145; &amp;#145;RF02K-LIFNR&amp;#146; &amp;#145;TEST1&amp;#146;,&lt;/P&gt;&lt;P&gt;&amp;#145; &amp;#145; &amp;#145;RF02K-D0010&amp;#146; &amp;#145;X&amp;#146;,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;#145;1&amp;#146; &amp;#145;SAPMF02K&amp;#146; &amp;#145;0110&amp;#146;,&lt;/P&gt;&lt;P&gt;&amp;#145; &amp;#145; &amp;#145;LFA1-STRAS&amp;#146;, &amp;#145;123 Main St.&amp;#146;,&lt;/P&gt;&lt;P&gt;&amp;#145; &amp;#145; &amp;#145;BDC_OKCODE&amp;#146;, &amp;#145;/11&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM POPULATE_BDC_TAB USING FLAG VAR1 VAR2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR BDC_TAB.&lt;/P&gt;&lt;P&gt;IF FLAG = &amp;#145;1&amp;#146;.&lt;/P&gt;&lt;P&gt;BDC_TAB-PROGRAM = VAR1.&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNPRO = VAR2..&lt;/P&gt;&lt;P&gt;BDC_TAB-DYNBEGIN = &amp;#145;X&amp;#146;.&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;BDC_TAB-FNAM = VAR1.&lt;/P&gt;&lt;P&gt;BDC_TAB-FVAL = VAR2.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND BDC_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This two subroutine method to fill the BDC table is preferable because the &amp;#147;POPULATE_BDC_TABLE&amp;#148; subroutine is reusable throughout all batch input programs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Example #1 - Change Vendor (Call Transaction Method)&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Example #1- Declaration Section&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT Y180DM10.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BDC_TAB LIKE STANDARD TABLE OF&lt;/P&gt;&lt;P&gt;BDCDATA INITIAL SIZE 6 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;INFILE(20) VALUE &amp;#145;/tmp/bc180_file4&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF INREC.&lt;/P&gt;&lt;P&gt;VENDNUM LIKE LFA1-LIFNR.&lt;/P&gt;&lt;P&gt;STREET LIKE LFA1-STRAS.&lt;/P&gt;&lt;P&gt;END OF INREC.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PARAMETERS: DISPMODE DEFAULT &amp;#145;A&amp;#146;,&lt;/P&gt;&lt;P&gt;UPDAMODE DEFAULT &amp;#145;S&amp;#146;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;OPEN DATASET INFILE&lt;/P&gt;&lt;P&gt;FOR INPUT IN TEXT MODE.&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;READ DATASET INFILE INTO INREC.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt; &amp;gt; 0. EXIT. ENDIF.&lt;/P&gt;&lt;P&gt;PERFORM FILL_BDC_TAB.&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;FK02&amp;#146;&lt;/P&gt;&lt;P&gt;USING BDC_TAB&lt;/P&gt;&lt;P&gt;MODE DISPMODE&lt;/P&gt;&lt;P&gt;UPDATE UPDAMODE.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt; &amp;gt; 0.&lt;/P&gt;&lt;P&gt;WRITE: /&amp;#145;ERROR&amp;#146;. &lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;CLOSE DATASET INFILE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;synchronous updating&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;&amp;#133;&amp;#133;&amp;#133;&lt;/P&gt;&lt;P&gt;PERFORM FILL_BDC_TAB.&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;FK02&amp;#146;&lt;/P&gt;&lt;P&gt;USING BDC_TAB&lt;/P&gt;&lt;P&gt;MODE &amp;#145;N&amp;#146;&lt;/P&gt;&lt;P&gt;UPDATE &amp;#145;S&amp;#146;.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt; &amp;gt; 0.&lt;/P&gt;&lt;P&gt;WRITE: /&amp;#145;ERROR&amp;#146;. &lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With synchronous updating, we can check SY-SUBRC to determine the success of the transaction and the actual update to the database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;asynchronous updating&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;&amp;#133;&amp;#133;&amp;#133;&lt;/P&gt;&lt;P&gt;PERFORM FILL_BDC_TAB.&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;FK02&amp;#146;&lt;/P&gt;&lt;P&gt;USING BDC_TAB&lt;/P&gt;&lt;P&gt;MODE &amp;#145;N&amp;#146;&lt;/P&gt;&lt;P&gt;UPDATE &amp;#145;A&amp;#146;.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt; &amp;gt; 0.&lt;/P&gt;&lt;P&gt;WRITE: /&amp;#145;ERROR&amp;#146;. &lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With asynchronous updating, we can check SY-SUBRC to determine the success of the transaction only, not the actual update to the database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Error Handling&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Write an error report.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Send the record(s) in error to an error file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Create a batch input session with the record(s) in error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To store error messages ( CALL TRANSACTION )&lt;/P&gt;&lt;P&gt;data: begin of Tab_Mess occurs 0.&lt;/P&gt;&lt;P&gt;include structure bdcmsgcoll.&lt;/P&gt;&lt;P&gt;data : end of Tab_Mess,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;FK02&amp;#146; USING BDC_TAB MODE &amp;#145;N&amp;#146; UPDATE &amp;#145;S&amp;#146; &lt;/P&gt;&lt;P&gt;MESSAGES INTO TAB_MESS.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC NE 0.&lt;/P&gt;&lt;P&gt;WRITE: / Tab_MESS-TCODE, Tab_MESS-DYNUMB, Tab_MESS-MSGTYP , &lt;/P&gt;&lt;P&gt;Tab_MESS-MSGID.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;i am giving you example for Change Vendor you practice for ur tcode&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For our example, we will use the &amp;#147;Change Vendor&amp;#148; transaction (&amp;#147;FK02&amp;#148;) to add a street address to an already existing vendor.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #1&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Use &amp;#147;System&amp;amp;#61664;Status&amp;#148; menu path to determine online program name (SAPMF02K), screen number (0110)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #2&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Use &amp;#147;F1&amp;#148; key and &amp;#147;Technical Info&amp;#148; pushbutton in each screen field to be filled to determine the field name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #3&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;Determine how to proceed in the transaction&lt;/P&gt;&lt;P&gt;(save the record by clicking on the &amp;#145;Save&amp;#146; pushbutton or pressing the &amp;#145;F11&amp;#146; key).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;BDC Table Contents&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;After researching the transaction we can determine the contents of the BDC table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PROGRAM DYNPRO DYNBEGIN FNAM FVAL&lt;/P&gt;&lt;P&gt;SAMPF02K 0106 X &lt;/P&gt;&lt;P&gt;RF02K-LIFNR TEST1&lt;/P&gt;&lt;P&gt;RF02K-D0110 X&lt;/P&gt;&lt;P&gt;SAMPF02K 0110 X &lt;/P&gt;&lt;P&gt;LFA1-STRAS 123 Main St.&lt;/P&gt;&lt;P&gt;BDC_OKCODE /11&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Batch Input Methods&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;#147;CALL TRANSACTION USING&amp;#148;&lt;/P&gt;&lt;P&gt;STATEMENT&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Call transaction - for data transfer&lt;/P&gt;&lt;P&gt;Processing batch input data with CALL TRANSACTION USING is the faster of the two recommended data transfer methods. In this method, legacy data is processed inline in your data transfer program. &lt;/P&gt;&lt;P&gt;Syntax:&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;lt;tcode&amp;gt;&lt;/P&gt;&lt;P&gt;USING &amp;lt;bdc_tab&amp;gt;&lt;/P&gt;&lt;P&gt;MODE &amp;lt;mode&amp;gt;&lt;/P&gt;&lt;P&gt;UPDATE &amp;lt;update&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A Display all&lt;/P&gt;&lt;P&gt;E Display errors only&lt;/P&gt;&lt;P&gt;N No display&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;S Synchronous&lt;/P&gt;&lt;P&gt;A Asynchronous&lt;/P&gt;&lt;P&gt;L Local update&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;The process flow of CALL TRANSACTION&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A program that uses CALL TRANSACTION USING to process legacy data should execute thefollowing steps:&lt;/P&gt;&lt;P&gt;Prepare a BDCDATA structure for the transaction that you wish to run. &lt;/P&gt;&lt;P&gt;Prepare a internal table to store error messages Tab_Mess like structure of BDCMSGCOLL.&lt;/P&gt;&lt;P&gt;With a CALL TRANSACTION USING statement, call the transaction and prepare the BDCDATA structure. For example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;MM01' USING BDCDATA MODE 'A' UPDATE 'S'. MESSAGES INTO TAB_MESS.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;&amp;lt;Error_handling&amp;gt;.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Overview of Batch Input Session&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The first batch input method is to create a batch input session. It is the processing of this batch input session that updates the database, not the execution of the batch input program. i am giving you example for Change Vendor you practice for ur tcode &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For our example, we will use the &amp;#147;Change Vendor&amp;#148; transaction (&amp;#147;FK02&amp;#148;) to add a street address to an already existing vendor.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #1&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Use &amp;#147;System&amp;amp;#61664;Status&amp;#148; menu path to determine online program name (SAPMF02K), screen number (0110)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #2&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Use &amp;#147;F1&amp;#148; key and &amp;#147;Technical Info&amp;#148; pushbutton in each screen field to be filled to determine the field name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Step #3&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;Determine how to proceed in the transaction&lt;/P&gt;&lt;P&gt;(save the record by clicking on the &amp;#145;Save&amp;#146; pushbutton or pressing the &amp;#145;F11&amp;#146; key).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;BDC Table Contents&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;After researching the transaction we can determine the contents of the BDC table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PROGRAM DYNPRO DYNBEGIN FNAM FVAL&lt;/P&gt;&lt;P&gt;SAMPF02K 0106 X &lt;/P&gt;&lt;P&gt;RF02K-LIFNR TEST1&lt;/P&gt;&lt;P&gt;RF02K-D0110 X&lt;/P&gt;&lt;P&gt;SAMPF02K 0110 X &lt;/P&gt;&lt;P&gt;LFA1-STRAS 123 Main St.&lt;/P&gt;&lt;P&gt;BDC_OKCODE /11&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Batch Input Methods&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;#147;CALL TRANSACTION USING&amp;#148;&lt;/P&gt;&lt;P&gt;STATEMENT&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Call transaction - for data transfer&lt;/P&gt;&lt;P&gt;Processing batch input data with CALL TRANSACTION USING is the faster of the two recommended data transfer methods. In this method, legacy data is processed inline in your data transfer program. &lt;/P&gt;&lt;P&gt;Syntax:&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;lt;tcode&amp;gt;&lt;/P&gt;&lt;P&gt;USING &amp;lt;bdc_tab&amp;gt;&lt;/P&gt;&lt;P&gt;MODE &amp;lt;mode&amp;gt;&lt;/P&gt;&lt;P&gt;UPDATE &amp;lt;update&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A Display all&lt;/P&gt;&lt;P&gt;E Display errors only&lt;/P&gt;&lt;P&gt;N No display&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;S Synchronous&lt;/P&gt;&lt;P&gt;A Asynchronous&lt;/P&gt;&lt;P&gt;L Local update&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;The process flow of CALL TRANSACTION&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A program that uses CALL TRANSACTION USING to process legacy data should execute thefollowing steps:&lt;/P&gt;&lt;P&gt;Prepare a BDCDATA structure for the transaction that you wish to run. &lt;/P&gt;&lt;P&gt;Prepare a internal table to store error messages Tab_Mess like structure of BDCMSGCOLL.&lt;/P&gt;&lt;P&gt;With a CALL TRANSACTION USING statement, call the transaction and prepare the BDCDATA structure. For example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL TRANSACTION &amp;#145;MM01' USING BDCDATA MODE 'A' UPDATE 'S'. MESSAGES INTO TAB_MESS.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;&amp;lt;Error_handling&amp;gt;.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Overview of Batch Input Session&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The first batch input method is to create a batch input session. It is the processing of this batch input session that updates the database, not the execution of the batch input program. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Reward if usefull&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Oct 2007 07:01:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/create-material-master-data/m-p/2867227#M672656</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-05T07:01:48Z</dc:date>
    </item>
  </channel>
</rss>

