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

Issue in reading session logs

Former Member
0 Likes
1,068

Hi All,

I have a requirement to post Customer Invoice in SAP as well a Clearing document against the same using the data from the 3rd party system.

I am using the below 3 FMs to post the Clearing document.

'POSTING_INTERFACE_START'

'POSTING_INTERFACE_CLEARING'

'POSTING_INTERFACE_END'.

Following this I am submitting the session and then attempting to read the session logs.

SUBMIT rsbdcsub WITH mappe EQ lv_session WITH fehler EQ ' '

WITH z_verarb EQ gc_set

EXPORTING LIST TO MEMORY AND RETURN.

WAIT UP TO 1 SECONDS.

I am able to read the session logs only if the WAIT statement is provided as indicated above.

Also in certain cases, I am not able to read the session logs. I assume its because the wait time is not sufficient.

Is there a way to handle this situation since WAIT more than 1 seconds will not be a good option.

I have tried commit work and wait but that doesnt serve my purpose.

Please let me know your inputs.

Thanks,

Binu

Hi All,

I have a requirement to post Customer Invoice in SAP as well a Clearing document against the same using the data from the 3rd party system.

I am using the below 3 FMs to post the Clearing document.

'POSTING_INTERFACE_START'

'POSTING_INTERFACE_CLEARING'

'POSTING_INTERFACE_END'.

Following this I am submitting the session and then attempting to read the session logs.

SUBMIT rsbdcsub WITH mappe EQ lv_session WITH fehler EQ ' '

WITH z_verarb EQ gc_set

EXPORTING LIST TO MEMORY AND RETURN.

WAIT UP TO 1 SECONDS.

I am able to read the session logs only if the WAIT statement is provided as indicated above.

Also in certain cases, I am not able to read the session logs. I assume its because the wait time is not sufficient.

Is there a way to handle this situation since WAIT more than 1 seconds will not be a good option.

I have tried commit work and wait but that doesnt serve my purpose.

Please let me know your inputs.

Thanks,

Binu

8 REPLIES 8
Read only

ThomasZloch
Active Contributor
0 Likes
1,025

Based on the explanation of the AND RETURN option

http://help.sap.com/abapdocu_70/en/ABAPSUBMIT.htm#!ABAP_ONE_ADD@1@

which is actually not 100% clear to me, you might try once without AND RETURN and see if this helps.

Thomas

Read only

HermannGahm
Product and Topic Expert
Product and Topic Expert
0 Likes
1,025

Hi,

how is the parameter I_UPDATE of the function module 'POSTING_INTERFACE_START' set?

In case it is set to 'S' or 'L' your update should be synchronous and the data should be 'ready'

after the end of the function modules. In case of 'A' (asynchronous update) you may have to

wait till the update is done... .

Kind regards,

Hermann

Read only

0 Likes
1,025

Hi Hermann,

I am not passing any value for the importing parameter, I_UPDATE. The default value for this parameter is 'S'.

Is there anything else you can think of to resolve this issue?

Thanks,

Binu

Read only

HermannGahm
Product and Topic Expert
Product and Topic Expert
0 Likes
1,025

Hi,

how about I_FUNCTION. Are you using 'C' or 'B'?

with 'C' and i_UPDATE 'L' or 'S' it should work i think.

Kind regards,

Hermann

Read only

0 Likes
1,025

Hi,

I am using session processing so have set I_FUNCTION as 'B'.

Thanks,

Binu

Read only

HermannGahm
Product and Topic Expert
Product and Topic Expert
0 Likes
1,025

ok. I_UPDATE is only valid for I_FUNCTION 'C'.

Could you try I_FUNCTION 'C'?

Kind regards,

Hermann

Read only

0 Likes
1,025

Hi,

I want to do it using the session method.

Thanks,

Binu

Read only

HermannGahm
Product and Topic Expert
Product and Topic Expert
0 Likes
1,025

Hi,

i think the bathinput seesion is started asynchronously... .

I'm not sure if or how you could be notified from the transaction end.

The other option is to wait like you are doing it... , sorry.

Kind regards,

Hermann