<?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: Z Tables aupdate - performance tips in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587670#M23549</link>
    <description>&lt;P&gt;Sandra,&lt;/P&gt;
  &lt;P&gt;Thanks for your post.&lt;/P&gt;
  &lt;P&gt;As I see it, the problem of using a MODIFY statement is that I would need to create (and populate) a very large&lt;EM&gt; itab&lt;/EM&gt; (&amp;gt;8M records), update its columns and run the modify afterwards. I worry mostly about the "loading" part. ¿How efficient would that be?&lt;/P&gt;
  &lt;P&gt;Thanks again,&lt;/P&gt;
  &lt;P&gt;Luis&lt;BR /&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 23 Mar 2018 19:54:30 GMT</pubDate>
    <dc:creator>luis_rod</dc:creator>
    <dc:date>2018-03-23T19:54:30Z</dc:date>
    <item>
      <title>Z Tables aupdate - performance tips</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587668#M23547</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;
  &lt;P&gt;We need to update a lot of our Z tables (some of them quite big) and would appreciate any performance tips (besides the obvious "create an appropiate index").&lt;/P&gt;
  &lt;P&gt;Our problem, in pseudo-code, is as follows:&lt;/P&gt; 
  &lt;PRE&gt;&lt;CODE&gt;LOOP until eof.
  SELECT single record k1,  f1, f2, f3 from ZDB001.
  NF1 = F1*X. NF2 = F2*X. NF3 = F3*X.
  UPDATE ZDB001 SET F1 = NF1,  F2=NF2,  F3= NF3 where key = zdb001~k1.
ENDLOOP.&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;In other words, loop thru the table, updating some (currency) columns according to a simple formula. As I see it,the bottleneck would be, of course,, in the SELECT/UPDATE access times. Were I be working with Db2, for instance, I would create some SQL functions and run a massive UPDATE statement (something that, AFAIK, can't be done in the SAP version we are currently using).&lt;/P&gt;
  &lt;P&gt;Any ideas?&lt;/P&gt;
  &lt;P&gt;Thanks in advance,&lt;/P&gt;
  &lt;P&gt;Luis&lt;/P&gt;</description>
      <pubDate>Fri, 23 Mar 2018 16:00:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587668#M23547</guid>
      <dc:creator>luis_rod</dc:creator>
      <dc:date>2018-03-23T16:00:00Z</dc:date>
    </item>
    <item>
      <title>Re: Z Tables aupdate - performance tips</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587669#M23548</link>
      <description>&lt;P&gt;I don't know whether the dbsl for DB/2 is optimized for doing bulk SQL updates as Oracle do, but it's worth trying to create an updatable DDIC view with only the key fields + the fields you want to update, and do a :&lt;/P&gt;
  &lt;P&gt;MODIFY updatableview FROM TABLE itab.&lt;/P&gt;
  &lt;P&gt;Of course, you won't create an updatable view for every group of fields you need to mass update, so it should be done only if the performance tests show there's a clear benefit.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Mar 2018 16:25:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587669#M23548</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2018-03-23T16:25:54Z</dc:date>
    </item>
    <item>
      <title>Re: Z Tables aupdate - performance tips</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587670#M23549</link>
      <description>&lt;P&gt;Sandra,&lt;/P&gt;
  &lt;P&gt;Thanks for your post.&lt;/P&gt;
  &lt;P&gt;As I see it, the problem of using a MODIFY statement is that I would need to create (and populate) a very large&lt;EM&gt; itab&lt;/EM&gt; (&amp;gt;8M records), update its columns and run the modify afterwards. I worry mostly about the "loading" part. ¿How efficient would that be?&lt;/P&gt;
  &lt;P&gt;Thanks again,&lt;/P&gt;
  &lt;P&gt;Luis&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Mar 2018 19:54:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587670#M23549</guid>
      <dc:creator>luis_rod</dc:creator>
      <dc:date>2018-03-23T19:54:30Z</dc:date>
    </item>
    <item>
      <title>Re: Z Tables aupdate - performance tips</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587671#M23550</link>
      <description>&lt;P&gt;You may do a loop with a given number of rows each time : SELECT * FROM updatableview PACKAGE SIZE 100000 ... ENDSELECT (or using its counter part OPEN CURSOR ... FETCH NEXT ... CLOSE CURSOR).&lt;/P&gt;</description>
      <pubDate>Fri, 23 Mar 2018 20:14:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587671#M23550</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2018-03-23T20:14:38Z</dc:date>
    </item>
    <item>
      <title>Re: Z Tables aupdate - performance tips</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587672#M23551</link>
      <description>&lt;P&gt;I think that would be an acceptable compromise. Half way between single selects/updates (which are quite inefficient) and pre-loading huge itabs.&lt;/P&gt;
  &lt;P&gt;Thanks again,&lt;/P&gt;
  &lt;P&gt;Luis&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Mar 2018 20:19:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/z-tables-aupdate-performance-tips/m-p/587672#M23551</guid>
      <dc:creator>luis_rod</dc:creator>
      <dc:date>2018-03-23T20:19:39Z</dc:date>
    </item>
  </channel>
</rss>

