‎2007 Mar 01 9:47 AM
we declare a variable eg:- bdc like bdcdata .......... what can we use d variable for???
why is it used??
‎2007 Mar 01 10:17 AM
hi,
you have declare internal table like BDCDATA.
the dat from internal table is not pass directly to database table,it has to go through the transaction.
you need to pass data to particular screen and to particular screen-field.Data is passed to transaction in particular format hence the need for batch input structure.
this structure is BDCDATA structure wwhich can contain the batch input data for only single run of a transaction.
BDCDATA structure consists of
PROGRAM : Name of the program associated with screen.
DYNPRO : Number of screen.length(4). set this for the first record for the screen.
DYNBEGIN: indicates the first record for the screen.Length(1).
set this field to X only for the first record
FNAM : name of the field.Length(35).
FVAL : value of the field. length(132).
hope this helps you.
pls:award points.
sri
‎2007 Mar 01 9:49 AM
it is a predefined structure that is capable of holding the SCREEN FLOW and DATA population information for a particular transaction.
BDCDATA has field like the screen in which the fields are there, the main program for that screen.
the field name which is to be populated, the value that is to be passed to that field, the user command that is executed etc.
Regards,
Ravi
‎2007 Mar 01 10:17 AM
hi,
you have declare internal table like BDCDATA.
the dat from internal table is not pass directly to database table,it has to go through the transaction.
you need to pass data to particular screen and to particular screen-field.Data is passed to transaction in particular format hence the need for batch input structure.
this structure is BDCDATA structure wwhich can contain the batch input data for only single run of a transaction.
BDCDATA structure consists of
PROGRAM : Name of the program associated with screen.
DYNPRO : Number of screen.length(4). set this for the first record for the screen.
DYNBEGIN: indicates the first record for the screen.Length(1).
set this field to X only for the first record
FNAM : name of the field.Length(35).
FVAL : value of the field. length(132).
hope this helps you.
pls:award points.
sri
‎2007 Mar 01 10:24 AM
loop at it_kna into record.
perform bdc_dynpro using 'SAPMF02D' '0105'.
perform bdc_field using 'BDC_CURSOR'
'RF02D-KTOKD'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'RF02D-KUNNR'
record-kunnr_001.
perform bdc_field using 'RF02D-BUKRS'
record-bukrs_002.
perform bdc_field using 'RF02D-KTOKD'
record-ktokd_003.
perform bdc_dynpro using 'SAPMF02D' '0110'.
perform bdc_field using 'BDC_CURSOR'
'KNA1-SPRAS'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'KNA1-ANRED'
record-anred_004.
perform bdc_field using 'KNA1-NAME1'
record-name1_005.
perform bdc_field using 'KNA1-SORTL'
record-sortl_006.
perform bdc_field using 'KNA1-ORT01'
record-ort01_007.
perform bdc_field using 'KNA1-PSTLZ'
record-pstlz_008.
perform bdc_field using 'KNA1-LAND1'
record-land1_009.
perform bdc_field using 'KNA1-SPRAS'
record-spras_010.
perform bdc_dynpro using 'SAPMF02D' '0120'.
perform bdc_field using 'BDC_CURSOR'
'KNA1-LIFNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMF02D' '0130'.
perform bdc_field using 'BDC_CURSOR'
'KNBK-BANKS(01)'.
perform bdc_field using 'BDC_OKCODE'
'=ENTR'.
perform bdc_dynpro using 'SAPMF02D' '0210'.
perform bdc_field using 'BDC_CURSOR'
'KNB1-AKONT'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'KNB1-AKONT'
record-akont_011.
perform bdc_dynpro using 'SAPMF02D' '0215'.
perform bdc_field using 'BDC_CURSOR'
'KNB1-ZTERM'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMF02D' '0220'.
perform bdc_field using 'BDC_CURSOR'
'KNB5-MAHNA'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_dynpro using 'SAPMF02D' '0230'.
perform bdc_field using 'BDC_CURSOR'
'KNB1-VRSNR'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_transaction using 'FD01'.
refresh it_bdc.
endloop.
‎2007 Mar 01 11:21 AM
The bdc flow is controlled by screen numbers, program names and value of the fileds. For the program to navigate through the screens information needs to be stored this itab.
This would more clear if u can open any BDC program and see it in debugging mode
Reward with points if this is useful
‎2007 Mar 02 8:42 AM
In oder to encourge people to answer your Queries. Reward them with points