<?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: Get deleted operations through code in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/get-deleted-operations-through-code/m-p/523590#M18928</link>
    <description>&lt;P&gt;You can call FM CO_MK_DISTRIBUTION_FLAG_set before you call the BAPI and&lt;/P&gt;&lt;P&gt;than you will get the deleted operations as well.&lt;/P&gt;&lt;P&gt;Example:&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'CO_MK_DISTRIBUTION_FLAG_SET'&lt;BR /&gt;      EXPORTING&lt;BR /&gt;        flag_distribution = abap_true.&lt;BR /&gt;        CALL FUNCTION 'BAPI_ALM_ORDER_GET_DETAIL'&lt;BR /&gt;          EXPORTING&lt;BR /&gt;            number        = ls_sel_order-orderid&lt;BR /&gt;*   IMPORTING&lt;BR /&gt;*           ES_HEADER     =&lt;BR /&gt;*           ES_SRVDATA    =&lt;BR /&gt;*           ES_REFORDER_ITEM               =&lt;BR /&gt;*           ES_JVA_DATA   =&lt;BR /&gt;          TABLES&lt;BR /&gt;*           ET_PARTNER    =&lt;BR /&gt;            et_operations = it_oper&lt;BR /&gt;*           ET_COMPONENTS =&lt;BR /&gt;*           ET_RELATIONS  =&lt;BR /&gt;*           ET_SRULES     =&lt;BR /&gt;*           ET_OLIST      =&lt;BR /&gt;*           ET_OPROL      =&lt;BR /&gt;*           ET_TEXTS      =&lt;BR /&gt;*           ET_TEXT_LINES =&lt;BR /&gt;*           ET_PRTS       =&lt;BR /&gt;*           ET_COSTS_SUM  =&lt;BR /&gt;*           ET_COSTS_DETAILS               =&lt;BR /&gt;            return        = it_ret_detail&lt;BR /&gt;*           EXTENSION_IN  =&lt;BR /&gt;*           EXTENSION_OUT =&lt;BR /&gt;*           ET_REFORDER_SERNO_OLIST        =&lt;BR /&gt;*           ET_SERVICEOUTLINE              =&lt;BR /&gt;*           ET_SERVICELINES                =&lt;BR /&gt;*           ET_SERVICELIMIT                =&lt;BR /&gt;*           ET_SERVICECONTRACTLIMITS       =&lt;BR /&gt;*           ET_PERMIT     =&lt;BR /&gt;*           ET_PERMIT_ISSUE                =&lt;BR /&gt;*           ET_ADDITIONAL_TEXTS            =&lt;BR /&gt;          .&lt;BR /&gt;CALL FUNCTION 'CO_MK_DISTRIBUTION_FLAG_SET'&lt;BR /&gt;  EXPORTING&lt;BR /&gt;    flag_distribution       = abap_false.&lt;/P&gt;</description>
    <pubDate>Wed, 27 Apr 2022 11:29:51 GMT</pubDate>
    <dc:creator>simon_filiz</dc:creator>
    <dc:date>2022-04-27T11:29:51Z</dc:date>
    <item>
      <title>Get deleted operations through code</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/get-deleted-operations-through-code/m-p/523588#M18926</link>
      <description>&lt;P&gt;Hello all!&lt;/P&gt;
  &lt;P&gt;I was needing to retrieve operations that have been deleted in IW32 with an REL status. It seems that I could use the bapi BAPI_ALM_ORDER_GET_DETAIL by requesting use of the ET_OPERATIONS parameter. However the code hits a FM called CO_MK_DISTRIBUTION_FLAG_GET to determine a Boolean on the variable lv_distribution. This determines whether or not the deleted operations will be retrieved as part of the return results. It is currently always returns false which means ultimately that it will not return any deleted operations if any. &lt;/P&gt;
  &lt;P&gt;Is there another way to return deleted operations through this bapi or is there an alternative?&lt;/P&gt;
  &lt;P&gt;Thanks!&lt;/P&gt;
  &lt;P&gt;Rene&lt;/P&gt;</description>
      <pubDate>Tue, 09 Jan 2018 21:10:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/get-deleted-operations-through-code/m-p/523588#M18926</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2018-01-09T21:10:42Z</dc:date>
    </item>
    <item>
      <title>Re: Get deleted operations through code</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/get-deleted-operations-through-code/m-p/523589#M18927</link>
      <description>&lt;P&gt;I found an alternative that I thought I would pass along in case someone needs it.&lt;/P&gt;
  &lt;P&gt;&lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;TYPES: BEGIN OF t_deleted_ops, 
	aufpl TYPE co_aufpl,
	ops TYPE vornr, 
       END OF t_deleted_ops.
DATA: lt_deleted_ops TYPE TABLE OF t_deleted_ops.
DATA: lt_ops TYPE &amp;lt;your itab&amp;gt;.

SELECT aufpl vornr 
  FROM afvc INTO TABLE lt_deleted_ops 
FOR ALL ENTRIES IN lt_ops 
 WHERE aufpl = lt_ops-aufpl 
   AND phflg = 'X'.
&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt; lt_deleted_ops now has the deleted operations for the aufpl from the AFVC table.&lt;/P&gt;
  &lt;P&gt;Rene&lt;/P&gt;</description>
      <pubDate>Wed, 10 Jan 2018 19:54:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/get-deleted-operations-through-code/m-p/523589#M18927</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2018-01-10T19:54:00Z</dc:date>
    </item>
    <item>
      <title>Re: Get deleted operations through code</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/get-deleted-operations-through-code/m-p/523590#M18928</link>
      <description>&lt;P&gt;You can call FM CO_MK_DISTRIBUTION_FLAG_set before you call the BAPI and&lt;/P&gt;&lt;P&gt;than you will get the deleted operations as well.&lt;/P&gt;&lt;P&gt;Example:&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'CO_MK_DISTRIBUTION_FLAG_SET'&lt;BR /&gt;      EXPORTING&lt;BR /&gt;        flag_distribution = abap_true.&lt;BR /&gt;        CALL FUNCTION 'BAPI_ALM_ORDER_GET_DETAIL'&lt;BR /&gt;          EXPORTING&lt;BR /&gt;            number        = ls_sel_order-orderid&lt;BR /&gt;*   IMPORTING&lt;BR /&gt;*           ES_HEADER     =&lt;BR /&gt;*           ES_SRVDATA    =&lt;BR /&gt;*           ES_REFORDER_ITEM               =&lt;BR /&gt;*           ES_JVA_DATA   =&lt;BR /&gt;          TABLES&lt;BR /&gt;*           ET_PARTNER    =&lt;BR /&gt;            et_operations = it_oper&lt;BR /&gt;*           ET_COMPONENTS =&lt;BR /&gt;*           ET_RELATIONS  =&lt;BR /&gt;*           ET_SRULES     =&lt;BR /&gt;*           ET_OLIST      =&lt;BR /&gt;*           ET_OPROL      =&lt;BR /&gt;*           ET_TEXTS      =&lt;BR /&gt;*           ET_TEXT_LINES =&lt;BR /&gt;*           ET_PRTS       =&lt;BR /&gt;*           ET_COSTS_SUM  =&lt;BR /&gt;*           ET_COSTS_DETAILS               =&lt;BR /&gt;            return        = it_ret_detail&lt;BR /&gt;*           EXTENSION_IN  =&lt;BR /&gt;*           EXTENSION_OUT =&lt;BR /&gt;*           ET_REFORDER_SERNO_OLIST        =&lt;BR /&gt;*           ET_SERVICEOUTLINE              =&lt;BR /&gt;*           ET_SERVICELINES                =&lt;BR /&gt;*           ET_SERVICELIMIT                =&lt;BR /&gt;*           ET_SERVICECONTRACTLIMITS       =&lt;BR /&gt;*           ET_PERMIT     =&lt;BR /&gt;*           ET_PERMIT_ISSUE                =&lt;BR /&gt;*           ET_ADDITIONAL_TEXTS            =&lt;BR /&gt;          .&lt;BR /&gt;CALL FUNCTION 'CO_MK_DISTRIBUTION_FLAG_SET'&lt;BR /&gt;  EXPORTING&lt;BR /&gt;    flag_distribution       = abap_false.&lt;/P&gt;</description>
      <pubDate>Wed, 27 Apr 2022 11:29:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/get-deleted-operations-through-code/m-p/523590#M18928</guid>
      <dc:creator>simon_filiz</dc:creator>
      <dc:date>2022-04-27T11:29:51Z</dc:date>
    </item>
  </channel>
</rss>

