<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Problem with BAPI_PO_CREATE1 in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6107999#M1361667</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;PO HEADER data&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;w_header-comp_code = '3082'.&lt;/P&gt;&lt;P&gt;w_header-doc_type = 'Z0RD'.&lt;/P&gt;&lt;P&gt;w_header-created_by = sy-uname.&lt;/P&gt;&lt;P&gt;w_header-vendor = '0005021295'.&lt;/P&gt;&lt;P&gt;w_header-pmnttrms = 'Z004'.&lt;/P&gt;&lt;P&gt;w_header-purch_org = 'P000'.&lt;/P&gt;&lt;P&gt;w_header-pur_group = '052'.&lt;/P&gt;&lt;P&gt;w_header-doc_date = '20080901'.&lt;/P&gt;&lt;P&gt;w_header-zzexptype = '9015'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;w_headerx-comp_code = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-doc_type = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-created_by = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-vendor = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-pmnttrms = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-purch_org = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-pur_group = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-doc_date = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-zzexptype = 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'BAPI_PO_CREATE1'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;   poheader                     = w_header&lt;/P&gt;&lt;P&gt;   poheaderx                    = w_headerx&lt;/P&gt;&lt;P&gt; IMPORTING&lt;/P&gt;&lt;P&gt;   exppurchaseorder             = po_numb&lt;/P&gt;&lt;P&gt; TABLES&lt;/P&gt;&lt;P&gt;   return                       = i_return&lt;/P&gt;&lt;P&gt;   poitem                       = i_line&lt;/P&gt;&lt;P&gt;   poitemx                      = i_linex&lt;/P&gt;&lt;P&gt;   poaddrdelivery               = i_po_deladd&lt;/P&gt;&lt;P&gt;   poschedule                   = i_posch&lt;/P&gt;&lt;P&gt;   poschedulex                  = i_poschx&lt;/P&gt;&lt;P&gt;   poaccount                    = i_po_act&lt;/P&gt;&lt;P&gt;   poaccountx                   = i_po_actx&lt;/P&gt;&lt;P&gt;   poservices                   = i_po_ser.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'&lt;/P&gt;&lt;P&gt; EXPORTING&lt;/P&gt;&lt;P&gt;   wait          = 'X'    .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 12 Oct 2009 11:36:04 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-10-12T11:36:04Z</dc:date>
    <item>
      <title>Problem with BAPI_PO_CREATE1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6107996#M1361664</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt; I have added a Field Expense type(char 4 and maintained the values in Table Maintainance Generator) in Strctures 'BAPIMEPOHEADER' and 'BAPIMEPOHEADERX' (char 1 only). while executing the BAPI_PO_CREATE1. it is giving the error as 'Please specify Valid Expense type'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Deepthi.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Sep 2009 13:45:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6107996#M1361664</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-11T13:45:35Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with BAPI_PO_CREATE1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6107997#M1361665</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Did you inserted X to the BAPIMEPOHEADERX or you tried to insert the first character the value?&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Sep 2009 14:42:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6107997#M1361665</guid>
      <dc:creator>Peter_Inotai</dc:creator>
      <dc:date>2009-09-11T14:42:39Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with BAPI_PO_CREATE1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6107998#M1361666</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt; I have inserted 'X' in BAPIMEPOHEADERX.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The below is my Code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN __default_attr="red" __jive_macro_name="color"&gt;Moderator message - Please respect the 2,500 character maximum when posting. Post only the relevant portions of code&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Deepthi.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Rob Burbank on Sep 11, 2009 11:57 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Sep 2009 15:55:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6107998#M1361666</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-11T15:55:56Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with BAPI_PO_CREATE1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6107999#M1361667</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;PO HEADER data&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;w_header-comp_code = '3082'.&lt;/P&gt;&lt;P&gt;w_header-doc_type = 'Z0RD'.&lt;/P&gt;&lt;P&gt;w_header-created_by = sy-uname.&lt;/P&gt;&lt;P&gt;w_header-vendor = '0005021295'.&lt;/P&gt;&lt;P&gt;w_header-pmnttrms = 'Z004'.&lt;/P&gt;&lt;P&gt;w_header-purch_org = 'P000'.&lt;/P&gt;&lt;P&gt;w_header-pur_group = '052'.&lt;/P&gt;&lt;P&gt;w_header-doc_date = '20080901'.&lt;/P&gt;&lt;P&gt;w_header-zzexptype = '9015'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;w_headerx-comp_code = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-doc_type = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-created_by = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-vendor = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-pmnttrms = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-purch_org = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-pur_group = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-doc_date = 'X'.&lt;/P&gt;&lt;P&gt;w_headerx-zzexptype = 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'BAPI_PO_CREATE1'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;   poheader                     = w_header&lt;/P&gt;&lt;P&gt;   poheaderx                    = w_headerx&lt;/P&gt;&lt;P&gt; IMPORTING&lt;/P&gt;&lt;P&gt;   exppurchaseorder             = po_numb&lt;/P&gt;&lt;P&gt; TABLES&lt;/P&gt;&lt;P&gt;   return                       = i_return&lt;/P&gt;&lt;P&gt;   poitem                       = i_line&lt;/P&gt;&lt;P&gt;   poitemx                      = i_linex&lt;/P&gt;&lt;P&gt;   poaddrdelivery               = i_po_deladd&lt;/P&gt;&lt;P&gt;   poschedule                   = i_posch&lt;/P&gt;&lt;P&gt;   poschedulex                  = i_poschx&lt;/P&gt;&lt;P&gt;   poaccount                    = i_po_act&lt;/P&gt;&lt;P&gt;   poaccountx                   = i_po_actx&lt;/P&gt;&lt;P&gt;   poservices                   = i_po_ser.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'&lt;/P&gt;&lt;P&gt; EXPORTING&lt;/P&gt;&lt;P&gt;   wait          = 'X'    .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Oct 2009 11:36:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6107999#M1361667</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-10-12T11:36:04Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with BAPI_PO_CREATE1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6108000#M1361668</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;
REPORT  ZPURCHASEORDER.
data:
header like BAPIMEPOHEADER,
headerx like BAPIMEPOHEADERX,
it_item like standard table of BAPIMEPOITEM,
it_itemx like standard table of BAPIMEPOITEMX,
return like standard table of BAPIRET2,
wa_item like BAPIMEPOITEM,
wa_itemx like BAPIMEPOITEMX,
p_int type i,
p_matnr like mara-matnr,
p_pono like ekko-ebeln.

DATA: BEGIN OF BAPIRETURN OCCURS 0.
        INCLUDE STRUCTURE BAPIRET2.
DATA: END OF BAPIRETURN.
constants:
c_x type c value 'X'.
header-comp_code = '3000'.
header-doc_type = 'DP25'.
header-creat_date = sy-datum.
header-item_intvl = '10'.
header-vendor = 'ARAMI-00'.
header-langu = sy-langu.
header-pmnttrms = '0001'.
header-purch_org = '3000'.
header-pur_group = '010'.
header-currency = 'USD'.
headerx-comp_code = c_x.
headerx-doc_type = c_x.
headerx-creat_date = c_x.
headerx-item_intvl = c_x .
headerx-vendor = c_x.
headerx-langu = c_x.
headerx-pmnttrms = c_x .
headerx-purch_org = c_x.
headerx-pur_group = c_x.
*LOOP AT it_final2 INTO wa_final2.
p_int = p_int + 10.
wa_item-po_item = p_int.
p_matnr = 'T-SRM01'.
CALL FUNCTION 'CONVERSION_EXIT_MATN1_INPUT'
EXPORTING
input = p_matnr
IMPORTING
output = p_matnr
EXCEPTIONS
length_error = 1
OTHERS = 2.
*IF sy-subrc = 0.
*MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
*WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
*ENDIF.
wa_item-material = p_matnr.
wa_item-plant = '3200'.
wa_item-quantity = 100.
wa_item-conf_ctrl = 'Z01'.
wa_item-ACKN_REQD = 'X'.
WA_ITEM-ERS = ''.
APPEND wa_item TO it_item.
wa_itemx-po_item = p_int.
wa_itemx-material = c_x.
wa_itemx-plant = c_x .
wa_itemx-stge_loc = c_x .
wa_itemx-quantity = c_x .
wa_itemx-item_cat = c_x .
wa_itemx-acctasscat = c_x .
wa_itemx-conf_ctrl = 'X'.
wa_itemx-ACKN_REQD = 'X'.
WA_ITEMX-ERS = 'X'.
APPEND wa_itemx TO it_itemx.
*ENDLOOP.
CALL FUNCTION 'BAPI_PO_CREATE1'
EXPORTING
poheader = header
poheaderx = headerx
IMPORTING
exppurchaseorder = p_pono
TABLES
return = return
poitem = it_item
poitemx = it_itemx.
 CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
           EXPORTING
                WAIT   = 'X'
           IMPORTING
                RETURN = BAPIRETURN.


write:/ p_pono.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Oct 2009 11:49:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6108000#M1361668</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-10-12T11:49:16Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with BAPI_PO_CREATE1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6108001#M1361669</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Pass the custome field ZZEXP_TYPE (Expense type) in Extensionin tables paramaetr of BAPI_PO_CREATE1 as below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : i_extensionin    TYPE STANDARD TABLE OF bapiparex,&lt;/P&gt;&lt;P&gt;w_extensionin    TYPE bapiparex.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Extension to add Expense Type only&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt; IF NOT  w_src-zzexptype IS INITIAL.&lt;/P&gt;&lt;P&gt; w_extensionin-structure = 'BAPI_TE_MEPOHEADER'.&lt;/P&gt;&lt;P&gt;w_extensionin-valuepart1+10(4) = w_src-zzexptype.&lt;/P&gt;&lt;P&gt;APPEND w_extensionin TO i_extensionin.&lt;/P&gt;&lt;P&gt;CLEAR w_extensionin.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;w_extensionin-structure = 'BAPI_TE_MEPOHEADERX'.&lt;/P&gt;&lt;P&gt;w_extensionin-valuepart1+10(4) = 'X'.&lt;/P&gt;&lt;P&gt;APPEND w_extensionin TO i_extensionin.&lt;/P&gt;&lt;P&gt;CLEAR w_extensionin.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Call BAPI&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      CALL FUNCTION 'BAPI_PO_CREATE1'&lt;/P&gt;&lt;P&gt;        EXPORTING&lt;/P&gt;&lt;P&gt;          poheader          = w_poheader&lt;/P&gt;&lt;P&gt;          poheaderx         = w_poheaderx&lt;/P&gt;&lt;P&gt;        IMPORTING&lt;/P&gt;&lt;P&gt;          exppurchaseorder  = gv_ebeln&lt;/P&gt;&lt;P&gt;        TABLES&lt;/P&gt;&lt;P&gt;        return            = i_return&lt;/P&gt;&lt;P&gt;        poitem            = i_poitem[]&lt;/P&gt;&lt;P&gt;        poitemx           = i_poitemx[]&lt;/P&gt;&lt;P&gt;        poaddrdelivery    = i_poaddrdel[]&lt;/P&gt;&lt;P&gt;        poaccount         = i_poaccount[]&lt;/P&gt;&lt;P&gt;        poaccountx        = i_poaccountx[]&lt;/P&gt;&lt;P&gt;        extensionin       = i_extensionin[].&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Commit the Transaction&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'&lt;/P&gt;&lt;P&gt;        EXPORTING&lt;/P&gt;&lt;P&gt;          wait = 'X'.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Dec 2009 07:23:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-bapi-po-create1/m-p/6108001#M1361669</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-12-31T07:23:23Z</dc:date>
    </item>
  </channel>
</rss>

