‎2010 Jul 27 7:03 AM
In return, I'm getting the message PO changed but the data is not updated (PO not changed), even after BAPI_TRANSACTION_COMMIT at the end.
‎2010 Jul 27 9:29 AM
Hello,
Have a look on poitmeX. You must repeat the valu in the 2 tables.
Exemple ok below
DATA: poitem TYPE STANDARD TABLE OF bapimepoitem,
wa_poitem TYPE bapimepoitem,
poitemx TYPE STANDARD TABLE OF bapimepoitemx,
wa_poitemx TYPE bapimepoitemx.
data wt_return type TABLE OF bapiret2.
wa_poitem-po_item = '10'.
wa_poitem-acknowl_no = 'Thierry OK via BAPI'.
wa_poitem-ackn_reqd = 'X'.
APPEND wa_poitem TO poitem.
wa_poitemx-po_item = '10'.
wa_poitemx-acknowl_no = 'X'.
wa_poitemx-ackn_reqd = 'X'.
APPEND wa_poitemx TO poitemx.
CALL FUNCTION 'BAPI_PO_CHANGE'
EXPORTING
purchaseorder = '4500059607'
TABLES
return = wt_return
poitem = poitem
poitemx = poitemx
.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
EXPORTING
wait = space.
Thierry
Edited by: Thierry RICARD on Jul 27, 2010 10:41 AM
Edited by: Thierry RICARD on Jul 27, 2010 10:57 AM
‎2010 Jul 27 10:02 AM