Skip to Content

BAPI_PO_CREATE1 error

Hi Guys,

I was able to create PO previously however there is no conditions tab.

So what I did was add a table for the conditions tab. Below is my code snippet:

x_pocond-itm_number = x_convert-fld33.
x_pocond-cond_type = 'PMP0'.
x_pocond-cond_value = x_convert-fld21.
x_pocond-change_id = 'I'.
x_pocond-conpricdat = sy-datum.
x_pocond-currency = 'PHP'.
x_pocond-cond_st_no = '001'.
x_pocond-currency_iso = 'PHP'.
x_pocond-cond_unit = 'PC'.
x_pocond-cond_p_unt = '1'.
APPEND x_pocond TO i_pocond.
CLEAR x_pocond.


*** flags
x_pocondx-itm_number = x_convert-fld33.
x_pocondx-cond_type = 'X'.
x_pocondx-cond_value = 'X'.
x_pocondx-change_id = 'X'.
x_pocondx-conpricdat = 'X'.
x_pocondx-currency = 'X'.
x_pocondx-cond_st_no = 'X'.
x_pocondx-currency_iso = 'X'.
x_pocondx-cond_unit = 'X'.
x_pocondx-cond_p_unt = 'X'.
APPEND x_pocondx TO i_pocondx.
CLEAR x_pocondx.

What did I miss? Where is my mistake?

BAPI_PO_CREATE1 is my bapi.

Thanks.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    May 11, 2017 at 08:32 AM

    Hi Guys,

    I know the answer

    BAPIMEPOITEM-GR_IND = 'X'

    BAPIMEPOITEM-IR_IND = 'X'

    These two fields should always be populated.

    PO created with conditions tab now.

    Thanks again.

    Add comment
    10|10000 characters needed characters exceeded

  • May 10, 2017 at 12:18 PM

    Hi,

    Create one manually then use bapi_po_getdetail to figure out how the structures should be filled and passed on to bapi_po_create1.

    Kind regards, Rob Dielemans

    Add comment
    10|10000 characters needed characters exceeded

  • May 11, 2017 at 08:05 AM

    Hi Guys,

    I did follow the bapi_po_getdetail and copied the entries of the manually created PO.

    I was not able to create a po.

    This is the error produced:

    For items without invoice receipt, please enter price 0

    Please help.

    Appreciate the reply above as well.

    Thanks.

    Add comment
    10|10000 characters needed characters exceeded