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

Wait until the session has been processed

sagar-acharya
Participant
0 Likes
883

Hi folks,

I have a report in which I create and trigger an SM35 session. I use RSBDCSUB report to do the same.

Now, is there anyway to wait until the session has been processed? I mean, I need to do a few things in the report only after the session has been processed.

Thanks

Sagar

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
688

Look at

Rob

4 REPLIES 4
Read only

Former Member
0 Likes
689

Look at

Rob

Read only

Former Member
0 Likes
688

Hi,

You could try checking the job status (table TBTCO) inside a DO or WHILE loop. To pause up to 5 seconds between your lookup on TBTCO, you can call function module 'RZL_SLEEP'.

If checking TBTCO does not work out for you, you can try the same loop logic with a call to function module 'ENQUEUE_BDC_QID' instead of looking up the job status. If the enqueue has been released then the job has finished.

Regards,

James G.

Read only

naimesh_patel
Active Contributor
0 Likes
688

Hello,

try like ..

Do.

select single from apqi

into l_apqi

WHERE DATATYP = 'BDC'

AND MANDANT = SY-MANDT

AND GROUPID = group name.

if l_apqi-state = 'F'.

exit.

endif.

enddo.

But keep mind, to break the do loop after certain time.

Regards,

Naimesh

Read only

sagar-acharya
Participant
0 Likes
688

Thank you all. Checking job status helped.