2010 May 28 2:53 PM
Hi all,
In BDC i am using ROLE BACK WORK. It is not working.
Let me explain clearly.
At certain case i need to create Vendor and Customer
Perform Create_vendor " Through BDC
If Vendor_success = 'X'. "Flag for Vendor success
perform Customer.
endif.
here if customer is not created i need to ROLLBACK vendor.
In the CTU parameters i took update as 'L'.
But it is not working properly.
regards,
Sri
Hi all,
In BDC i am using ROLE BACK WORK. It is not working.
Let me explain clearly.
At certain case i need to create Vendor and Customer
Perform Create_vendor " Through BDC
If Vendor_success = 'X'. "Flag for Vendor success
perform Customer.
endif.
here if customer is not created i need to ROLLBACK vendor.
In the CTU parameters i took update as 'L'.
But it is not working properly.
regards,
Sri
2010 May 28 3:01 PM
Its not possible to roll back in bdc.
because CTU does the db commit automatically.
You can try something like simulation mode execution.
or you can try using the class/methods of CMD_EI_API & VMD_EI_API . But im not sure whether it requires a commit work explicitly at last.
2010 May 28 3:29 PM
Hi Keshav,
Thanks for your replay, I checked the class. but
I am new to class even those are for XK01 and XD01 but i want for FK01 and FD01.
Is there any way with BDC.
thank you
Regards,
sri
2010 May 28 7:31 PM
Sri, as told previously, no way, you can't rollback a BDC.
Ana Luisa, RACOMMIT just allows to continue the BDC after a COMMIT WORK has been done inside the BDC (by default it stops). So it doesn't prevent the COMMIT WORK to be done.
I have added your question to the BDC FAQ wiki: http://wiki.sdn.sap.com/wiki/display/ABAP/BatchInputFAQ
Maybe you can try with IDocs: if they allow packets of more than 1 IDoc, then they don't do any database commit.
2010 Jun 02 11:08 AM
Hi Sandra,
Thank you for the clarification. I misunderstood the online help.
Regards,
Ana Luisa.
2010 May 28 4:29 PM
Hi Sri,
Are you using the standard BI program RFBIKF00 or a call transaction?
With the call transaction you have the OPTIONS FROM opt addition where you can specify wether a COMMIT WORK terminates batch input processing or not (opt component RACOMMIT)
Regards,
Ana Luisa.
2010 May 28 8:48 PM
HI for creating customer are you refering to any of the data related to vendor ??
Why dont you create customer first and when sy-subrc = 0 ( after call transaction of customer ), then execute the vendor details.
2010 May 29 7:03 AM
Hi sandra,
Thank you for clarifying the issue.
and let me ask you a question, what is the use of CTU-parameters update into LOCAL.
Keshav it is Vice versa. if vendor not created, customer has to roll back.
Regards,
Sri
2010 Jun 02 12:23 PM
>
> what is the use of CTU-parameters update into LOCAL.
>
according to [wiki Batch Input - BDC|http://wiki.sdn.sap.com/wiki/display/ABAP/BatchInput-+BDC#BatchInput-BDC-Updatemode], CTU_PARAMS-UPDMODE = 'L' means:
> Local update task. Update function modules are executed as if SET UPDATE TASK LOCAL has been executed at the start of each LUW, i.e. they are executed in the same workprocess as the main program.
I let you refer to the [ABAP documentation of SET UPDATE TASK LOCAL|http://help.sap.com/abapdocu_70/en/ABAPSET_UPDATE_TASK_LOCAL.htm]