2022 Feb 16 7:45 AM
Hello,
I have managed to create a PO from PR using BAPI_PO_CREATE1, but the 'Closed' indicator (EBAN-EBAKZ), processing status (EBAN-STATU) or PO number (EBAN-EBELN) do not seem to be updated after committing the BAPI. I have passed the PR number and PR item number to BAPIMEPOITEM-PREQ_NO and BAPIMEPOITEM-PREQ_ITEM respectively in hope that it would automatically update EBELN in EBAN after commit
From what I have explored, BAPI_PR_CHANGE and BAPI_REQUISITION_CHANGE cannot change STATU or EBELN (unless if I have missed it), but BAPI_PR_CHANGE can edit EBAKZ.
Is there a way to update EBAN-EBELN to act as another indicator that the PR item is still open? Although I could've just used BAPI_PR_CHANGE to edit EBAKZ to indicate the PR is unavailable, I still need to display EBELN
P/S: The issue has been resolved by adding the highlighted lines in the image
2022 Feb 16 10:35 AM
Hi There,
I am checking the same in my system and after commit its updated by BAPI_PO_CREATE1, can you share the screenshot of successful execution.
2022 Feb 16 10:35 AM
Hi There,
I am checking the same in my system and after commit its updated by BAPI_PO_CREATE1, can you share the screenshot of successful execution.
2022 Feb 16 12:38 PM
Hello!
I am very happy to say that I have just resolved this issue minutes ago. Turns out I forgot to flag the PR number and PR item in Table POITEMX of BAPI_PO_CREATE1, therefore the PO was not properly referencing the PR. The issue was resolved by adding the following:
LT_POITEMX-PREQ_NO = 'X'.
LT_POITEMX-PREQ_ITEM = 'X'.
Thank you for your response! It is very encouraging for me to ask more questions on the forum, especially considering this is my first.