on 2016 Jul 28 9:39 AM
Hi experts,
I have a problem with programming a report for purchase order confirmation in SRM 7.13 classic scenario.
I use the following method calls described here:
/sapsrm/cl_pdo_bo_conf_adv=>create_conf_adv_instance
CALL METHOD lo_bo_conf->get_header_detail
CALL METHOD lo_bo_conf->update_header
CALL METHOD lo_bo_conf->get_item_details
CALL METHOD lo_bo_conf->update_item
CALL METHOD lo_bo_conf->/sapsrm/if_pdo_base~submit_update
CALL METHOD lo_bo_conf->set_save_or_park_flag
CALL METHOD lo_bo_conf->confirm
All works fine without errors but the last method lo_bo_conf->confirm drops a relevant class attribute MV_HEADER_GUID.
Because of the missing GUID I get an exception /sapsrm/cx_pdo_abort_gen with message „Interface data contains errors“.
With setting the right GUID in the debugger again, I get the error BBP_PD001 "Buffer table not up to date".
What’s going wrong?
Regards,
Jürgen
Request clarification before answering.
Hi Jurgen
I see some missing code as below . Also please try to do the GR of the goods from portal just to be sure there is no data errors
Also check the roles and authorization of the user. User should have central confirmation role assigned if he/she is not the requester of PO
CALL METHOD lo_conf->/sapsrm/if_pdo_adv_base~submit_decision
.
CALL METHOD lo_conf->/sapsrm/if_pdo_base~save
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
Let me know if that helps.
Regards
Vinita
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vinita,
thanks for your reply.
Yes finally you have to set a commit, but the error occurs before.
I have found the solution and will share it for all others running into the same issue.
Info:
Most SRM systems using workflows for approvals.
In this case you must create the new instance with an other class.
Solution:
Instead of using /sapsrm/cl_pdo_bo_conf_adv=>create_conf_adv_instance
you have to use /sapsrm/cl_pdo_fact_conf_adv=>create_new_instance.
Regards
Juergen
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.