‎2007 Apr 16 12:17 PM
Hi Guys,
I am trying to execution a transaction using Session method. I am not getting any errors in any of the Function Modules "BDC_OPEN_GROUP", "BDC_INSERT" or "BDC_INSERT". Everything is fine but ultimately when I go to SM35 transaction I don't find the sessions available.
could someone let me know what could be the problem.
Thanks,
ABAP'er.
‎2007 Apr 16 12:19 PM
Hi,
Just check whether you have enabled the<b> keep</b> option in BDC_OPEN_GROUP FM.
If you do no do so, after processing the session, the session name is removed from the log.
Hope this resolves your query.
Reward all the helpful answers.
Regards
‎2007 Apr 16 12:20 PM
Hi,
1. Make sure u finally use
BDC_CLOSE
2. Only after we use the above FM, the session really gets created.
regards,
amit m.
‎2007 Apr 16 12:23 PM
Hi Both,
I have used BDC_CLOSE_GROUP. I don't have problem in that.
I have even used KEEP = 'X'. I don't have problem in that but finally session does not get created.
Regards,
ABAP'er.
‎2007 Apr 16 12:26 PM
Hi again,
1. Then make sure sy-subrc is zero,
after each FM.
regards,
amit m.
‎2007 Apr 16 12:47 PM
Hi All,
It works find on the Development System and when it is Transported to Acceptance it does not work. Not able to figure out the reason.
I don't get any Error or SY-SUBRC <> 0.
Thanks,
ABAP'er.
‎2009 Oct 09 6:36 AM
Hello Abaper,
I am having the exact same issue. I get subrc eq 0 during creation of the session, but during close group it says session not created. Did u manage to solve the issue. It worked for me in dev and also in test before. but now when i test again its not working....do you have the solution yet?
thnx
salman
‎2007 Apr 16 12:23 PM
Hi friend,
I think u did mistake when ur providing the perameters.
Plz go through this u can check ur coding.
Open Batch Input group
CALL FUNCTION 'BDC_OPEN_GROUP'
EXPORTING
CLIENT = SY-MANDT
GROUP = GROUP
USER = USER
KEEP = KEEP.
Fill in the Data for Transaction in an internal table 'BDCDATA'
FORM INSERT_SCREEN USING PROGRAM DYNPRO.
CLEAR BDCDATA.
BDCDATA-PROGRAM = PROGRAM.
BDCDATA-DYNPRO = DYNPRO.
BDCDATA-DYNBEGIN = 'X'.
APPEND BDCDATA.
ENDFORM.
FORM INSERT_FIELD USING FNAM FVAL.
CLEAR BDCDATA.
BDCDATA-FNAM = FNAM.
BDCDATA-FVAL = FVAL.
APPEND BDCDATA.
ENDFORM.
Insert Transacton
CALL FUNCTION 'BDC_INSERT'
EXPORTING
TCODE = 'ME21'
TABLES
DYNPROTAB = BDCDATA.
Close Batch Input group
CALL FUNCTION 'BDC_CLOSE_GROUP'.
Finally to process Batch Input Session, first execute the BDC ABAP. This will create
a BDC session. Run transaction 'SM35' & processes the BDC session.
Some useful URLs
http://www.sap-img.com/abap/bdc-example-using-table-control-in-bdc.htm
http://www.sap-img.com/abap/learning-bdc-programming.htm
http://www.guidancetech.com/people/holland/sap/abap/zzsni001.htm
The difference between CallTransaction and Sessionmethod.
In Call Transaction, the transactions are triggered at the time of processing itself and so the ABAP program must do the error handling. It can also be used for real-time interfaces and custom error handling & logging features. Whereas in
Batch Input Sessions, the ABAP program creates a session with all the transactional data, and this session can be viewed, scheduled and processed (using Transaction SM35) at a later time. The latter technique has a built-in error processing mechanism too.
difference between batch input and call transaction in BDC
Session method.
1) synchronous processing.
2) can tranfer large amount of data.
3) processing is slower.
4) error log is created
5) data is not updated until session is processed.
Call transaction.
1) asynchronous processing
2) can transfer small amount of data
3) processing is faster.
4) errors need to be handled explicitly
5) data is updated automatically
regards,
P.Nag
‎2007 Apr 16 12:24 PM
Hi....
did you close the session with the FM <b>BDC_CLOSE_GROUP</b>.
Please check it once....
Regards,
Suresh.......
‎2013 Sep 25 6:10 AM
Hi Joseph
I faced the same problem. Please follow this link
http://http://scn.sap.com/thread/2078029
In SM35 select the session which is coming as being created and then press shift+f4. If it gets created now then the above mention thread will help.
Regards
Shivam Maurya