‎2008 May 30 4:28 AM
‎2008 May 30 4:58 AM
It is not at all clear.
You should know what fields you want to use for Batch upload using BDC. So you should have clear cut idea which fields u wanna use on specific screen. And also sometimes there will be some mandatory fields.
Anyway, Here is Simple BDC program for ME13 Transaction.
report ZVKBDCME13
no standard page heading line-size 255.
include bdcrecx1.
start-of-selection.
perform open_group.
perform bdc_dynpro using 'SAPMM06I' '0100'.
perform bdc_field using 'BDC_CURSOR'
'EINA-LIFNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'EINA-LIFNR'
'10099'.
perform bdc_field using 'EINA-MATNR'
'CCS-99'.
perform bdc_field using 'EINE-EKORG'
'3000'.
perform bdc_field using 'EINE-WERKS'
'3000'.
perform bdc_field using 'RM06I-NORMB'
'X'.
perform bdc_dynpro using 'SAPMM06I' '0101'.
perform bdc_field using 'BDC_CURSOR'
'EINA-INFNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMM06I' '0102'.
perform bdc_field using 'BDC_CURSOR'
'EINE-INFNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMM06I' '0105'.
perform bdc_field using 'BDC_CURSOR'
'EINE-INFNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMM06I' '0103'.
perform bdc_field using 'BDC_CURSOR'
'EINA-INFNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_transaction using 'ME13'.
perform close_group. Try it.
Reward if you find useful.
Chinna
‎2008 May 30 5:28 AM
hi
me13 is display the purchase info , how can u write BDC for me13
which transaction u want me11 or me12.
thanks
sitaram
‎2008 May 30 5:34 AM
hi,
Generally ME11 is used to create info records
or ME13 to change info records.
refer the code.
1.prepare a flat file. with th efollowing fields:
vendor,matrl no,pur grp,info record number.2.prepare an 2.internal table in compatible with falt file.
3. do the recording using transaction shdb
4, Create pgm and loop th eperform staements.
5.Change the recordinfg fields to itab fields
6. The tables are updated are as follows EINA ,EINE
-
report ZUK_BDC_ME13
no standard page heading line-size 255.
include bdcrecx1.
start-of-selection.
perform open_group.
loop at itab.
perform bdc_dynpro using 'SAPMM06I' '0100'.
perform bdc_field using 'BDC_CURSOR'
'EINA-MATNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'EINA-LIFNR'
'aaa'.
perform bdc_field using 'EINA-MATNR'
'000000000000000143'.
perform bdc_field using 'EINE-EKORG'
'0001'.
perform bdc_field using 'EINA-INFNR'
'5300000010'.
perform bdc_field using 'RM06I-NORMB'
'X'.
perform bdc_dynpro using 'SAPMM06I' '0101'.
perform bdc_field using 'BDC_CURSOR'
'EINA-INFNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMM06I' '0102'.
perform bdc_field using 'BDC_CURSOR'
'EINE-INFNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMM06I' '0105'.
perform bdc_field using 'BDC_CURSOR'
'EINE-INFNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMM06I' '0103'.
perform bdc_field using 'BDC_CURSOR'
'EINA-INFNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_transaction using 'ME13'.
endloop.
perform close_group.
*Reward if helpful
Rgds
Umakanth