Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

HOW CAN I CREAT MULTIPLE TRANSACTION IN A BDC_INSERT FUNCTION.

Former Member
0 Likes
618

HAI,

HOW CAN I CREAT MULTIPLE TRANSACTION IN A BDC_INSERT FUNCTION.

THANK YOU

ASHOK KUMAR

4 REPLIES 4
Read only

Former Member
0 Likes
588

Hi Ashok,

multiple transaction is possible using session method.

Have one BDC_OPEN_GROUP, multiple BDC_INSERT s and one BDC_CLOSE_GROUP.

You should have multiple BDC_INSERT s for multiple transactions.

call function BDC_OPENGROUP.

  • Build BDC data and cal lBDC_INSERT for transaction 1

  • Build BDC data and cal lBDC_INSERT for transaction 2

  • Build BDC data and cal lBDC_INSERT for transaction 3

paas the tcodes to bdc_insert.

call function BDC_CLOSE_GROUP.

Regards....

Arun.

Reward points if useful.

Read only

Former Member
0 Likes
588

Hi Ashok,

Multiple transactions can be called using session method.

First call BDC_OPEN_GROUP then BDC_INSERT once for each transaction and at last call BDC_CLOSE_GROUP

EX:

call function BDC_OPENGROUP.

Loop at itab1.

call function BDC_INSERT .

endloop.

Loop at itab2.

call function BDC_INSERT .

endloop.

.

.

.

.

.

call function BDC_CLOSE_GROUP.

Regds,

Younus

<b>Reward Helpful Answers</b>

Read only

Former Member
0 Likes
588

Hi Ashok,

Use BDC session method for that.

BDC_OPENGROUP.

loop at itab1.

BDC_INSERT.

"call transaction1

endloop.

loop at itab2.

BDC_INSERT.

"call transaction2

endloop.

.

.

.

.

.

BDC_CLOSEGROUP.

Regards,

Hemant

Read only

former_member223446
Active Participant
0 Likes
588

hi ashok

multiple transactions are done by using session method.

we can call bdc_insert function module several times in a single program.

data :begin of itxk01 occurs 0,

-


-


end of itxk01.

data :itbdcdata like bdcdata occurs 0 with header line.

call function gui_upload.

call bdc_open_group.

-


-


loop at itxk01.

refresh itxk01.

perform bdc-dynpro using 'prg' 'scr.'

perform bdc-filed using 'fnam' 'fval'.

-


-


call bdc-insert

-


endloop.

loop at itxk01.

refresh itxk01.

perform bdc-dynpro using 'prg' 'scr.'

perform bdc-filed using 'fnam' 'fval'.

-


-


call bdc-insert

-


endloop.

call bdc-close-group.

form bdc-dynpro using pr sc.

-


endform.

form bdc-dynpro using fn fv.

-


endform.

if helpful reward points

kiran