2006 Jan 26 4:55 AM
Hi,
this is what i want to achieve.
I am running an report which collect the Employee wage data based on some condition and populate Employee number, hourly rate and GL account in one internal table. I have to post these data to CO using transaction KBK6.
This report will be run once each month and i will have 2500 record in the internal table. I am going to use BDC to post this data to CO. I can not use call transaction (Background processing) because the requirement is, user should be able to to reporcess the records which have failed. I have recorded the KBK6 transaction and created a BDCDATA table as per the requirement.
Now the requirement is, i have to create a Bacth input session with this data and also with immediate processing. This all should be done programatically, i should not give any popup to user to select date/time of BDC Session.
If i use BDC_OPEN_GROUP, BDC_INSERT and BDC_CLOSE_GROUP, i can create an session but i cannot start immediately.
<b>So, is there any way to create a BDC session with BDCDATA table and also set it to process immediately. If anyone has any solution please let me know??</b>
2006 Jan 26 5:23 AM
Hi,
I guess you can schedule that program but it can't start immediate as it has to wait till work process is free.
Use the function module BP_JOBVARIANT_SCHEDULE .
http://help.sap.com/saphelp_erp2005/helpdata/en/fa/096cbe543b11d1898e0000e8322d00/frameset.htm
Regds,
Mithlesh
Message was edited by: Mithlesh Jha
2006 Jan 26 7:38 AM
Hi Pratik,
You can do this in a slightly different way.
For each input record, build BDCDATA and use CALL TRANSACTION with mode = 'N'. If the CALL TXN is successful, the data will be updated immediately.
If the CALL TXN fails (sy-subrc <> 0), then insert the BDCDATA in BDC session with BDC_INSERT.
At the end, you would have processed all successful records immediately and the failed records will be available in the BDC session for processing by user later.
Hope this helps,
Rao A
2006 Jan 26 8:22 AM