Skip to Content
0
Former Member
Mar 14, 2007 at 08:31 AM

BDC PROGRAM

14 Views

1)explain

tables : kna1.

data: begin of itab occurs 0,

kunnr like kna1-kunnr,

land1 like kna1-land1,

name1 like kna1-name1,

end of itab.

data: jtab like bdcdata occurs 0 with header line.

call function 'ws_upload'

exporting

filename = 'c:\ses.txt'.

filetype = 'dat'.

tables data_tab = itab.

call function 'bdc_open_group'.

exporting

client = sy-mandt.

group = 'abc'.

holddate =sy-datum.

keep = 'x'.

user = sy-uname.

loop at itab.

refresh jtab.

perform sub1 using 'yvtrans' 1000.

perform sub2 using 'kna1-kunnr',itab-kunnr.

perform sub2 using 'kna1-land1',itab-land1.

perform sub2 using 'kna1-name1',itab-name1.

call function 'bdc_insert'.

exporting

tcode = 'yvtrans'.

tables dynprotab = jtab.

endloop.

call function 'bdc_close_group'.

form sub1 using A B.

clear jtab.

jtab-program = A.

jtab-dynpro = B.

jtab-dynbegin = 'x'.

append jtab.

endform.

loop at itab.

perform sub1 using 'zc1' 100.

form sub2 using C D.

clear jtab.

jtab-fnam = C.

jtab-Fval =D.

append jtab.

endform.

loop at itab.

perform sub1 using 'zc1' 100.

perform sub2 using 'kna1-kunnr',itab-A.

perform sub2 using 'kna1-kunnr',itab-B.

FLAT FILE:

49811 IN FDDD

49812 IN DFFF

49813 IN XCXCC

YVTRANS:

3fields

vendor

country

name

buttons: display & exit.

1)how to create this yvtrans appl.

2)can u explain the above program.

3)what is jtab & itab.

jtab-program,jtab-dynpro,jtab-dynbegin.

jtab-fnam,jtab-fval

4)when to create flat file before the appl. or after the appl.

5) why we require jtab.what is use of jtab.

my emailid is lakshmisap@yahoo.com

Message was edited by:

lakshmi veera