<?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: BAPI_PO_CHANGE in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-po-change/m-p/3975813#M949596</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Firstly call function moduleBAPI_TRANSACTION_COMMIT&lt;/P&gt;&lt;P&gt;ater your BAPI_PO_CHANGE.&lt;/P&gt;&lt;P&gt;pls check the note in documentation below:&lt;/P&gt;&lt;P&gt;In the case of changes that are to be made via the BAPI_PO_CHANGE, a firewall first checks whether the relevant fields are changeable. This approach follows that of the online transaction&lt;/P&gt;&lt;P&gt;First check in your transaction whether the delivery date is changeable or not.&lt;/P&gt;&lt;P&gt;And also consult your functional guy.&lt;/P&gt;&lt;P&gt;I hope this will help you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 16 Jun 2008 06:27:34 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-06-16T06:27:34Z</dc:date>
    <item>
      <title>BAPI_PO_CHANGE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-po-change/m-p/3975812#M949595</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I want to change the quantity , price and schedule line delivery date, I am able to change quantity and price , but delivery date is not changing with BAPI&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;below is my code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA :po_items TYPE bapiekpo OCCURS 0 WITH HEADER LINE,&lt;/P&gt;&lt;P&gt;po_item_schedules TYPE bapieket OCCURS 0 WITH HEADER LINE,&lt;/P&gt;&lt;P&gt;return TYPE bapireturn OCCURS 0 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'BAPI_PO_GETDETAIL'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;purchaseorder = '4500000946'&lt;/P&gt;&lt;P&gt;items = 'X'&lt;/P&gt;&lt;P&gt;schedules = 'X'&lt;/P&gt;&lt;P&gt;TABLES&lt;/P&gt;&lt;P&gt;po_items = po_items&lt;/P&gt;&lt;P&gt;po_item_schedules = po_item_schedules&lt;/P&gt;&lt;P&gt;return = return .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;******For change BAPI&lt;/P&gt;&lt;P&gt;DATA : return1 TYPE bapiret2 OCCURS 0 WITH HEADER LINE,&lt;/P&gt;&lt;P&gt;poitem TYPE bapimepoitem OCCURS 0 WITH HEADER LINE,&lt;/P&gt;&lt;P&gt;poitemx TYPE bapimepoitemx OCCURS 0 WITH HEADER LINE,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;poschedule TYPE bapimeposchedule OCCURS 0 WITH HEADER LINE,&lt;/P&gt;&lt;P&gt;poschedulex TYPE bapimeposchedulx OCCURS 0 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT po_items.&lt;/P&gt;&lt;P&gt;CLEAR poitemx.&lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING po_items TO poitem.&lt;/P&gt;&lt;P&gt;poitemx-net_price = 'X'.&lt;/P&gt;&lt;P&gt;poitemx-quantity = 'X'.&lt;/P&gt;&lt;P&gt;poitem-quantity = 15.&lt;/P&gt;&lt;P&gt;poitemx-po_item = poitem-po_item.&lt;/P&gt;&lt;P&gt;poitemx-po_itemx = 'X'.&lt;/P&gt;&lt;P&gt;poitem-net_price = 3.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND poitem.&lt;/P&gt;&lt;P&gt;APPEND poitemx.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT po_item_schedules.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING po_item_schedules TO poschedule.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;poschedule-sched_line = 0001.&lt;/P&gt;&lt;P&gt;poschedule-delete_ind = 'X'.&lt;/P&gt;&lt;P&gt;poschedule-delivery_date = '20080710'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;poschedulex-PO_ITEM = 00010.&lt;/P&gt;&lt;P&gt;poschedulex-SCHED_LINE = 0001.&lt;/P&gt;&lt;P&gt;poschedulex-PO_ITEMX = 'X'.&lt;/P&gt;&lt;P&gt;poschedulex-SCHED_LINEX = 'X'.&lt;/P&gt;&lt;P&gt;poschedulex-QUANTITY = 'X'.&lt;/P&gt;&lt;P&gt;poschedulex-PO_ITEMX = 'X'.&lt;/P&gt;&lt;P&gt;poschedulex-SCHED_LINEX = 'X'.&lt;/P&gt;&lt;P&gt;poschedulex-DELETE_IND = 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND poschedule.&lt;/P&gt;&lt;P&gt;APPEND poschedulex.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'BAPI_PO_CHANGE'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;purchaseorder = '4500000946'&lt;/P&gt;&lt;P&gt;poheader = poheader&lt;/P&gt;&lt;P&gt;poheaderx = poheaderx&lt;/P&gt;&lt;P&gt;TABLES&lt;/P&gt;&lt;P&gt;return = return1&lt;/P&gt;&lt;P&gt;poitem = poitem&lt;/P&gt;&lt;P&gt;poitemx = poitemx&lt;/P&gt;&lt;P&gt;poschedule = poschedule&lt;/P&gt;&lt;P&gt;poschedulex = poschedulex&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;COMMIT WORK.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WRITE : 'DO'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks ,&lt;/P&gt;&lt;P&gt;Bijal&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Jun 2008 06:17:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-po-change/m-p/3975812#M949595</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-16T06:17:40Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_PO_CHANGE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-po-change/m-p/3975813#M949596</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Firstly call function moduleBAPI_TRANSACTION_COMMIT&lt;/P&gt;&lt;P&gt;ater your BAPI_PO_CHANGE.&lt;/P&gt;&lt;P&gt;pls check the note in documentation below:&lt;/P&gt;&lt;P&gt;In the case of changes that are to be made via the BAPI_PO_CHANGE, a firewall first checks whether the relevant fields are changeable. This approach follows that of the online transaction&lt;/P&gt;&lt;P&gt;First check in your transaction whether the delivery date is changeable or not.&lt;/P&gt;&lt;P&gt;And also consult your functional guy.&lt;/P&gt;&lt;P&gt;I hope this will help you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Jun 2008 06:27:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-po-change/m-p/3975813#M949596</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-16T06:27:34Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_PO_CHANGE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-po-change/m-p/3975814#M949597</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes the delivery date is changeable in transaction&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Jun 2008 06:39:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-po-change/m-p/3975814#M949597</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-16T06:39:05Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_PO_CHANGE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-po-change/m-p/3975815#M949598</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A few things can't work in your code:&lt;/P&gt;&lt;P&gt;- you delete the schedule line (poschedule-delete_ind = 'X'.)&lt;/P&gt;&lt;P&gt;- poschedulex-delivery_date is not flagged so delivery date is not registered to be changed&lt;/P&gt;&lt;P&gt;- poschedule-delivery_date is not a date field it is a 10 character field, you must not give the internal date format to the bapi but the external date format.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is your po_item_schedules loop reworked:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA: date      TYPE sy-datum.
  LOOP AT po_item_schedules.
    poschedule-po_item       = po_item_schedules-po_item.
    poschedule-sched_line    = po_item_schedules-serial_no.

    poschedulex-po_item       = po_item_schedules-po_item.
    poschedulex-sched_line    = po_item_schedules-serial_no.

    date = '20080710'.
    WRITE date TO poschedule-delivery_date.
    poschedulex-delivery_date = 'X'.

    APPEND poschedule.
    APPEND poschedulex.
  ENDLOOP.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Jun 2008 13:10:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-po-change/m-p/3975815#M949598</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-16T13:10:32Z</dc:date>
    </item>
  </channel>
</rss>

