<?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: Roll Back custom table updates if report dumps before COMMIT in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/roll-back-custom-table-updates-if-report-dumps-before-commit/m-p/314165#M4459</link>
    <description>&lt;P&gt;Look in your code for any &lt;A href="http://help-legacy.sap.com/abapdocu_751/en/abendb_commit.htm#@@ITOC@@ABENDB_COMMIT_1"&gt;Implicit Database Commits&lt;/A&gt;, are you able to remove those, in this case a database rollback will reverse the delete (e.g. call FM DB_ROLLBACK)&lt;/P&gt;&lt;P&gt;If
 not, then you can no longer reverse the changes so consider moving the 
delete and following insert open-sql statements to some &lt;A href="http://help-legacy.sap.com/abapdocu_751/en/abenupdate_function_module_glosry.htm"&gt;update function module&lt;/A&gt; called I&lt;A href="http://help-legacy.sap.com/abapdocu_751/en/abapcall_function_update.htm"&gt;N UPDATE TASK&lt;/A&gt;, so they won't be executed before the COMMIT-WORK.&lt;/P&gt;&lt;P&gt;Else you could load ZTST initial values in an internal 'old' table, remove the open-sql statements in the code, replace by adding records in an internal 'new' table and just before the  COMMIT, update the database table.&lt;/P&gt;&lt;P&gt;Regards,&lt;BR /&gt;Raymond&lt;/P&gt;</description>
    <pubDate>Thu, 16 Feb 2017 06:39:20 GMT</pubDate>
    <dc:creator>RaymondGiuseppi</dc:creator>
    <dc:date>2017-02-16T06:39:20Z</dc:date>
    <item>
      <title>Roll Back custom table updates if report dumps before COMMIT</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/roll-back-custom-table-updates-if-report-dumps-before-commit/m-p/314164#M4458</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I'm deleting all records from a custom table as the very first statement. After some 1000 line of codes I'm doing COMMIT WORK. If my program dumps in between I want all records in table as it is(NOT DELETED), but i find that my table is empty. Here is sample code below.&lt;/P&gt;&lt;P&gt;DELETE FROM ztest.&lt;/P&gt;&lt;P&gt;*****Some thousand line of codes.*** My program may dump here in between&lt;/P&gt;&lt;P&gt;IF sy-subrc eq 0.&lt;/P&gt;&lt;P&gt;COMMIT WORK.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;Please help me how to roll back custom table changes, if my report dumps in between.&lt;/P&gt;</description>
      <pubDate>Thu, 16 Feb 2017 05:52:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/roll-back-custom-table-updates-if-report-dumps-before-commit/m-p/314164#M4458</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2017-02-16T05:52:32Z</dc:date>
    </item>
    <item>
      <title>Re: Roll Back custom table updates if report dumps before COMMIT</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/roll-back-custom-table-updates-if-report-dumps-before-commit/m-p/314165#M4459</link>
      <description>&lt;P&gt;Look in your code for any &lt;A href="http://help-legacy.sap.com/abapdocu_751/en/abendb_commit.htm#@@ITOC@@ABENDB_COMMIT_1"&gt;Implicit Database Commits&lt;/A&gt;, are you able to remove those, in this case a database rollback will reverse the delete (e.g. call FM DB_ROLLBACK)&lt;/P&gt;&lt;P&gt;If
 not, then you can no longer reverse the changes so consider moving the 
delete and following insert open-sql statements to some &lt;A href="http://help-legacy.sap.com/abapdocu_751/en/abenupdate_function_module_glosry.htm"&gt;update function module&lt;/A&gt; called I&lt;A href="http://help-legacy.sap.com/abapdocu_751/en/abapcall_function_update.htm"&gt;N UPDATE TASK&lt;/A&gt;, so they won't be executed before the COMMIT-WORK.&lt;/P&gt;&lt;P&gt;Else you could load ZTST initial values in an internal 'old' table, remove the open-sql statements in the code, replace by adding records in an internal 'new' table and just before the  COMMIT, update the database table.&lt;/P&gt;&lt;P&gt;Regards,&lt;BR /&gt;Raymond&lt;/P&gt;</description>
      <pubDate>Thu, 16 Feb 2017 06:39:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/roll-back-custom-table-updates-if-report-dumps-before-commit/m-p/314165#M4459</guid>
      <dc:creator>RaymondGiuseppi</dc:creator>
      <dc:date>2017-02-16T06:39:20Z</dc:date>
    </item>
  </channel>
</rss>

