<?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: Performance in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579768#M261684</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Shejal,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do this way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;instead of second internal table,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT kunnr&lt;/P&gt;&lt;P&gt;name1&lt;/P&gt;&lt;P&gt;regio&lt;/P&gt;&lt;P&gt;INTO TABLE it_kna1&lt;/P&gt;&lt;P&gt;FROM kna1&lt;/P&gt;&lt;P&gt;FOR ALL ENTRIES IN it_vbpa&lt;/P&gt;&lt;P&gt;WHERE kunnr EQ it_vbpa-kunnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT kunnr&lt;/P&gt;&lt;P&gt;name1&lt;/P&gt;&lt;P&gt;regio&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;INTO table itab_kna1.&amp;lt;/b&amp;gt;  "declare itab_kna1 as same as it_kna1&lt;/P&gt;&lt;P&gt;FROM kna1&lt;/P&gt;&lt;P&gt;FOR ALL ENTRIES IN it_knvp&lt;/P&gt;&lt;P&gt;WHERE kunnr EQ it_knvp-kunnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;loop at itab_kna1.&lt;/P&gt;&lt;P&gt;move-corresponding itab_kna1 to it_kna1.&lt;/P&gt;&lt;P&gt;append it_kna1.&lt;/P&gt;&lt;P&gt;endloop.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vivek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 13 Sep 2006 14:24:39 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-09-13T14:24:39Z</dc:date>
    <item>
      <title>Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579766#M261682</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello friends,&lt;/P&gt;&lt;P&gt;I have to select data into an itab based on conditions from 2 different itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this piece of code wirks fine but i am kind of thinking it wouls take time so is there any simplier process.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    SELECT kunnr&lt;/P&gt;&lt;P&gt;           name1&lt;/P&gt;&lt;P&gt;           regio&lt;/P&gt;&lt;P&gt;      INTO TABLE it_kna1&lt;/P&gt;&lt;P&gt;      FROM kna1&lt;/P&gt;&lt;P&gt;       FOR ALL ENTRIES IN it_vbpa&lt;/P&gt;&lt;P&gt;       WHERE kunnr EQ it_vbpa-kunnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    SELECT kunnr&lt;/P&gt;&lt;P&gt;           name1&lt;/P&gt;&lt;P&gt;           regio&lt;/P&gt;&lt;P&gt;      INTO it_kna1&lt;/P&gt;&lt;P&gt;      FROM kna1&lt;/P&gt;&lt;P&gt;       FOR ALL ENTRIES IN it_knvp&lt;/P&gt;&lt;P&gt;       WHERE kunnr EQ it_knvp-kunnr.&lt;/P&gt;&lt;P&gt;      APPEND it_kna1.&lt;/P&gt;&lt;P&gt;    ENDSELECT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any advice,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Shejal Shetty.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:18:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579766#M261682</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-13T14:18:31Z</dc:date>
    </item>
    <item>
      <title>Re: Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579767#M261683</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Collect your customer numbers from it_vbpa and it_knvp into a third internal table and select from KNA1 based on this table.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:23:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579767#M261683</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-13T14:23:09Z</dc:date>
    </item>
    <item>
      <title>Re: Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579768#M261684</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Shejal,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do this way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;instead of second internal table,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT kunnr&lt;/P&gt;&lt;P&gt;name1&lt;/P&gt;&lt;P&gt;regio&lt;/P&gt;&lt;P&gt;INTO TABLE it_kna1&lt;/P&gt;&lt;P&gt;FROM kna1&lt;/P&gt;&lt;P&gt;FOR ALL ENTRIES IN it_vbpa&lt;/P&gt;&lt;P&gt;WHERE kunnr EQ it_vbpa-kunnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT kunnr&lt;/P&gt;&lt;P&gt;name1&lt;/P&gt;&lt;P&gt;regio&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;INTO table itab_kna1.&amp;lt;/b&amp;gt;  "declare itab_kna1 as same as it_kna1&lt;/P&gt;&lt;P&gt;FROM kna1&lt;/P&gt;&lt;P&gt;FOR ALL ENTRIES IN it_knvp&lt;/P&gt;&lt;P&gt;WHERE kunnr EQ it_knvp-kunnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;loop at itab_kna1.&lt;/P&gt;&lt;P&gt;move-corresponding itab_kna1 to it_kna1.&lt;/P&gt;&lt;P&gt;append it_kna1.&lt;/P&gt;&lt;P&gt;endloop.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vivek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:24:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579768#M261684</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-13T14:24:39Z</dc:date>
    </item>
    <item>
      <title>Re: Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579769#M261685</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; Insert this code before second select. This filters the existing kunnr from it_knvp.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
 loop at it_kna1.
   read table it_knvp with key kunnr = it_kna1-kunnr  binary search.
  if sy-usbrc = 0.
      delete it_knvp where kunnr = it_kna1-kunnr.
  endif.
 endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sailaja.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:27:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579769#M261685</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-13T14:27:16Z</dc:date>
    </item>
    <item>
      <title>Re: Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579770#M261686</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;run the program from se30 and see if the log will notice&lt;/P&gt;&lt;P&gt;about select problem  , &lt;/P&gt;&lt;P&gt;finger rule , in the "net" columne number have to be&lt;/P&gt;&lt;P&gt;under 10 precent above it  , its problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;also you can check total time for running  ,&lt;/P&gt;&lt;P&gt;and do test by changing the select .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and not advice one , is add index  ,&lt;/P&gt;&lt;P&gt;just in case of no other choice  .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2) active st05 and check the log  .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;replace the append with &lt;/P&gt;&lt;P&gt;appending corresponding fields to table ....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;goodlack  .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:27:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579770#M261686</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-13T14:27:34Z</dc:date>
    </item>
    <item>
      <title>Re: Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579771#M261687</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Shejal,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;U cud combine the KUNNR of IT_KNA1 and IT_KNVP into another internal table and Select frm KNA1 using that itab. That way, u have to fire only one Select query.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Johnson&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:28:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579771#M261687</guid>
      <dc:creator>former_member215243</dc:creator>
      <dc:date>2006-09-13T14:28:08Z</dc:date>
    </item>
    <item>
      <title>Re: Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579772#M261688</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt; Avoid using select .. endselect... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT kunnr
name1
regio
&amp;lt;b&amp;gt;INTO table it_kna11&amp;lt;/b&amp;gt;
FROM kna1
FOR ALL ENTRIES IN it_knvp
WHERE kunnr EQ it_knvp-kunnr.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Santosh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:28:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579772#M261688</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-13T14:28:51Z</dc:date>
    </item>
    <item>
      <title>Re: Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579773#M261689</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Shetty,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hey first thing first dont go for &lt;/P&gt;&lt;P&gt;SELECT......ENDSELECT.&lt;/P&gt;&lt;P&gt;statement.it will take more time.&lt;/P&gt;&lt;P&gt;better use the first one &lt;/P&gt;&lt;P&gt;SELECT kunnr&lt;/P&gt;&lt;P&gt;name1&lt;/P&gt;&lt;P&gt;regio&lt;/P&gt;&lt;P&gt;INTO TABLE it_kna1&lt;/P&gt;&lt;P&gt;FROM kna1&lt;/P&gt;&lt;P&gt;FOR ALL ENTRIES IN it_vbpa&lt;/P&gt;&lt;P&gt;WHERE kunnr EQ it_vbpa-kunnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Vikranth Khimavath&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:29:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579773#M261689</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-13T14:29:21Z</dc:date>
    </item>
    <item>
      <title>Re: Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579774#M261690</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Shejal,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; try using only one select from KNA1 table.&lt;/P&gt;&lt;P&gt; You are reading the same data for different set of kunnr. &lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt; Try to get all the kunnr in one table and then do a single select to KNA1 table. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Cheers&lt;/P&gt;&lt;P&gt; VJ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:32:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579774#M261690</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-13T14:32:11Z</dc:date>
    </item>
    <item>
      <title>Re: Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579775#M261691</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks everyone.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Shejal Shetty.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:39:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579775#M261691</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-13T14:39:48Z</dc:date>
    </item>
    <item>
      <title>Re: Performance</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579776#M261692</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;  One way to handle you case is using &amp;lt;b&amp;gt;"APPENDING TABLE"&amp;lt;/b&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EG:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;  SELECT kunnr name1 regio
      INTO TABLE it_kna1
      FROM kna1
      FOR ALL ENTRIES IN it_vbpa
      WHERE kunnr EQ it_vbpa-kunnr.

  SELECT kunnr name1 regio
      APPENDING CORRESPONDING FIELDS OF TABLE IT_KNA1
      FROM kna1
      FOR ALL ENTRIES IN it_knvp
      WHERE kunnr EQ it_knvp-kunnr.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  I sincerely advice you to extract data from KNA1 &lt;/P&gt;&lt;P&gt;irrespective of entries in IT_VBPA and IT_KNVP which &lt;/P&gt;&lt;P&gt;will be somewhat less and reduces the number of hits to &lt;/P&gt;&lt;P&gt;database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Eg:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;  SELECT kunnr name1 regio
      INTO TABLE it_kna1
      FROM kna1.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;   &lt;/P&gt;&lt;P&gt;  One shot you will have more than required data and &lt;/P&gt;&lt;P&gt;continous hits to database will be avoided.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind Regards&lt;/P&gt;&lt;P&gt;Eswar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2006 14:45:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance/m-p/1579776#M261692</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-13T14:45:11Z</dc:date>
    </item>
  </channel>
</rss>

