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

Function Module WS_DELIVERY_UPDATE

Former Member
0 Likes
2,908

Hello All,

I am using the function Module 'WS_DELIVERY_UPDATE' in LOOP to save the deliveries. While testing we found out following issue.

One of the delivery can not be saved due to some error. This error is given in the form of popup. As program runs in bacground, program is not able to handle this popup. So it comes out of the FM.

Now when this FM tries to update next delivery in the loop, it gives the same error(although that delivery is correct). We believe this is happening because internal tables, structure or error logs were not cleared/refreshed in the previous loop pass.

How can I handle this situation? I am not sure if commit, rollback or flush command will work. Please help.

Thanks!

Rohit

6 REPLIES 6
Read only

Former Member
0 Likes
1,771

Hi,

did you set one or both of the parameters IF_NO_INIT or IF_NO_BUFFER_REFRESH to 'X' ? That may be the reason!

Regards,

Klaus

Read only

0 Likes
1,771

Hello,

I am not passing any of the parameter as suggested by you. I am passing the following parameters to the FM

CALL FUNCTION 'WS_DELIVERY_UPDATE'

EXPORTING

vbkok_wa = wa_vbkok

commit = c_x

delivery = wa_delivery-refnum

IMPORTING

ef_error_any_0 = v_err1

ef_error_in_item_deletion_0 = v_err2

ef_error_in_pod_update_0 = v_err3

ef_error_in_interface_0 = v_err4

ef_error_in_goods_issue_0 = v_err5

ef_error_in_final_check_0 = v_err6

TABLES

vbpok_tab = it_vbpok

EXCEPTIONS

error_message = 99.

Please let me know which parameter can I use?

Read only

0 Likes
1,771

Hi,

parameters are ok. Didi you refresh VBPOK_TAB for each call, or are there some data remaining from last call?

Read only

0 Likes
1,771

Hi Klaus,

Yes all the exporting parameters are refreshed at the start of each loop pass.

Read only

0 Likes
1,771

Hi Rohit,

you can try to call fm RV_DELIVERY_INIT in error case of WS_DELIVERY_UPDATE and test it with several options (STATUS_BUFF_INIT = 'X', ...)

Read only

Former Member
0 Likes
1,771

Hey,

Did you uncomment all the error exception in IMPORTING Field