<?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: Truncate Command Not working in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/truncate-command-not-working/m-p/2996176#M707751</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You may want to Google TRUNCATE DB2. I'm not sure if you can do this, but there appear to be other options.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 26 Oct 2007 20:40:02 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-10-26T20:40:02Z</dc:date>
    <item>
      <title>Truncate Command Not working</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/truncate-command-not-working/m-p/2996174#M707749</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Folks, I have a SAP Table that I want to delete all the data from but still want to keep the table definition.. I dont want to fetch the records and then delete as this is a huge table so want to use a truncate command. The issue is that program has no syntax errors but it would not delete the data at all. Here is the code I have used and I am on a DB2 system, can someone help what I am doing wrong?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: exc_ref TYPE REF TO cx_sy_native_sql_error,&lt;/P&gt;&lt;P&gt;error_text TYPE string.&lt;/P&gt;&lt;P&gt;TRY.&lt;/P&gt;&lt;P&gt;EXEC SQL.&lt;/P&gt;&lt;P&gt;TRUNCATE TABLE S194&lt;/P&gt;&lt;P&gt;ENDEXEC.&lt;/P&gt;&lt;P&gt;CATCH cx_sy_native_sql_error INTO exc_ref.&lt;/P&gt;&lt;P&gt;error_text = exc_ref-&amp;gt;get_text( ).&lt;/P&gt;&lt;P&gt;ENDTRY.&lt;/P&gt;&lt;P&gt;IF SY-SUBRC = 0.&lt;/P&gt;&lt;P&gt;commit work.&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;write : / error_text .&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Ram Gowda&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Oct 2007 20:15:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/truncate-command-not-working/m-p/2996174#M707749</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-26T20:15:48Z</dc:date>
    </item>
    <item>
      <title>Re: Truncate Command Not working</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/truncate-command-not-working/m-p/2996175#M707750</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How about.....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;delete from s194 client specified where mandt = sy-mandt.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Oct 2007 20:25:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/truncate-command-not-working/m-p/2996175#M707750</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2007-10-26T20:25:42Z</dc:date>
    </item>
    <item>
      <title>Re: Truncate Command Not working</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/truncate-command-not-working/m-p/2996176#M707751</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You may want to Google TRUNCATE DB2. I'm not sure if you can do this, but there appear to be other options.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Oct 2007 20:40:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/truncate-command-not-working/m-p/2996176#M707751</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-26T20:40:02Z</dc:date>
    </item>
  </channel>
</rss>

