<?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 tuning in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113623#M983513</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;1. First of all try to avoid the use of  'INTO CORRESPONDING FIELDS OF TABLE ist_bseg '&lt;/P&gt;&lt;P&gt;Instead use &lt;STRONG&gt;'INTO TABLE ist_bseg'&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. Before using a internal table 'FOR ALL ENTRIES IN ist_bkpf'&lt;/P&gt;&lt;P&gt;check if the table is not empty, other wise all entries in select statemets will be executed.&lt;/P&gt;&lt;P&gt;ie &lt;STRONG&gt;'IF NOT ist_bkpf IS INITIAL'&lt;/STRONG&gt;. before select query.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;3. BSEG is a cluster table, it always take more time to fetch data compared to other transparent tables. To improve the performance you should select data using its secondary index .&lt;/P&gt;&lt;P&gt;Check if secondary index exists and find out the best possible for you. And then use it in where clause of select satement in same order as specified.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;plz reward if useful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks,&lt;/P&gt;&lt;P&gt;dhanashri.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Dhanashri Pawar on Jul 7, 2008 9:08 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 07 Jul 2008 07:08:22 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-07-07T07:08:22Z</dc:date>
    <item>
      <title>performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113617#M983507</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;SELECT bukrs&lt;/P&gt;&lt;P&gt;             belnr&lt;/P&gt;&lt;P&gt;             gjahr&lt;/P&gt;&lt;P&gt;             buzei&lt;/P&gt;&lt;P&gt;             matnr&lt;/P&gt;&lt;P&gt;             ebeln&lt;/P&gt;&lt;P&gt;             ebelp&lt;/P&gt;&lt;P&gt;             dmbtr&lt;/P&gt;&lt;P&gt;             hkont&lt;/P&gt;&lt;P&gt;             shkzg&lt;/P&gt;&lt;P&gt;             mwskz&lt;/P&gt;&lt;P&gt;             bschl&lt;/P&gt;&lt;P&gt;        FROM bseg&lt;/P&gt;&lt;P&gt;        INTO CORRESPONDING FIELDS OF TABLE ist_bseg&lt;/P&gt;&lt;P&gt;         FOR ALL ENTRIES IN ist_bkpf&lt;/P&gt;&lt;P&gt;       WHERE bukrs = ist_bkpf-bukrs&lt;/P&gt;&lt;P&gt;         AND belnr = ist_bkpf-belnr&lt;/P&gt;&lt;P&gt;         AND gjahr = ist_bkpf-gjahr&lt;/P&gt;&lt;P&gt;         AND hkont IN (c_hkont1, c_hkont2, c_hkont3, c_hkont4, c_hkont5, c_hkont6 ).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the above statement taks lots of time in exuquting because of large entries.&lt;/P&gt;&lt;P&gt;can any change in the above statement  which improve  performance of program&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 06:50:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113617#M983507</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-07T06:50:59Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113618#M983508</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;make sure that u have checked ist_bkpf[] is not initial before this select query...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Only if its not inintial then go for the select query....&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 06:53:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113618#M983508</guid>
      <dc:creator>former_member195383</dc:creator>
      <dc:date>2008-07-07T06:53:59Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113619#M983509</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; In the above statement use INTO TABLE ist_bseg instead of &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;INTO CORRESPONDING FIELDS OF TABLE ist_bseg.&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;Jaya Vani&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 06:54:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113619#M983509</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-07T06:54:51Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113620#M983510</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;You might have to consider joining BKPF and BSEG, instead of 2 select queries..and FOR ALL ENTRIES etc..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rgds,&lt;/P&gt;&lt;P&gt;Raghu.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 06:57:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113620#M983510</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-07T06:57:07Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113621#M983511</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;BSEG is a cluster table, it always take mote time to fetch data compare to transparent tables. To improve the performance u should select data from its Secondary Index tables like BSAK,BSAD,BSAS,BSIK,BSID etc. (whichever meets ur requirement).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Joy.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 06:59:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113621#M983511</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-07T06:59:24Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113622#M983512</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;when you use for all entries. u have to use like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if not ist_bkpf[] is initial.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select query.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 07:01:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113622#M983512</guid>
      <dc:creator>venkatasriram_mygapula</dc:creator>
      <dc:date>2008-07-07T07:01:58Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113623#M983513</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;1. First of all try to avoid the use of  'INTO CORRESPONDING FIELDS OF TABLE ist_bseg '&lt;/P&gt;&lt;P&gt;Instead use &lt;STRONG&gt;'INTO TABLE ist_bseg'&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. Before using a internal table 'FOR ALL ENTRIES IN ist_bkpf'&lt;/P&gt;&lt;P&gt;check if the table is not empty, other wise all entries in select statemets will be executed.&lt;/P&gt;&lt;P&gt;ie &lt;STRONG&gt;'IF NOT ist_bkpf IS INITIAL'&lt;/STRONG&gt;. before select query.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;3. BSEG is a cluster table, it always take more time to fetch data compared to other transparent tables. To improve the performance you should select data using its secondary index .&lt;/P&gt;&lt;P&gt;Check if secondary index exists and find out the best possible for you. And then use it in where clause of select satement in same order as specified.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;plz reward if useful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks,&lt;/P&gt;&lt;P&gt;dhanashri.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Dhanashri Pawar on Jul 7, 2008 9:08 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 07:08:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113623#M983513</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-07T07:08:22Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113624#M983514</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You're using BUKRS, BELNR and GJAHR in your WHERE clause and you can't do any better when selecting from BSEG.  Any query that selects a lot of data will inevitably take a long time, however well indexed it is.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You're also using HKONT in your query, so a better starting point for you might be to use a table like BSIS, which is indexed on BUKRS and HKONT (as already mentioned further up).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 09:48:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113624#M983514</guid>
      <dc:creator>christine_evans</dc:creator>
      <dc:date>2008-07-07T09:48:33Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113625#M983515</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;gt; Hi,&lt;/P&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;P&gt;&amp;gt;&amp;gt; 3. BSEG is a cluster table, it always take more time to fetch data compared to other transparent tables. To improve the performance you should select data using its secondary index .&lt;/P&gt;&lt;P&gt;&amp;gt; Check if secondary index exists and find out the best possible for you. And then use it in where clause of select satement in same order as specified.&lt;/P&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;P&gt;BSEG is a cluster table.  You can't create secondary indexes on cluster tables.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 09:50:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113625#M983515</guid>
      <dc:creator>christine_evans</dc:creator>
      <dc:date>2008-07-07T09:50:23Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113626#M983516</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;gt; Hello,&lt;/P&gt;&lt;P&gt;&amp;gt; You might have to consider joining BKPF and BSEG, instead of 2 select queries..and FOR ALL ENTRIES etc..&lt;/P&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;P&gt;BSEG is a cluster table.  You can't join to a cluster table.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 09:51:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113626#M983516</guid>
      <dc:creator>christine_evans</dc:creator>
      <dc:date>2008-07-07T09:51:23Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113627#M983517</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;BSEG is cluster table, when V fetch data from Cluster tables it always take more time to fetch the data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So better search for secondary tables which contain all field u want.(BSAK, BSIK,....)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;shaik sha vali.P&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 09:55:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113627#M983517</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-07T09:55:49Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113628#M983518</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;gt; Hi,&lt;/P&gt;&lt;P&gt;&amp;gt; BSEG is cluster table, when V fetch data from Cluster tables it always take more time to fetch the data.&lt;/P&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;P&gt;&amp;gt; So better search for secondary tables which contain all field u want.(BSAK, BSIK,....)&lt;/P&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;P&gt;&amp;gt; regards,&lt;/P&gt;&lt;P&gt;&amp;gt; shaik sha vali.P&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What is the point of advising the OP to use BSAK or BSIK when both will contain only vendor lines and are unlikely to contain the GL code lines that I'm assuming he is looking for?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Jul 2008 10:12:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113628#M983518</guid>
      <dc:creator>christine_evans</dc:creator>
      <dc:date>2008-07-07T10:12:59Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113629#M983519</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;ya but bsis table has not field like matnr, ebeln,ebelp which i want.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Jul 2008 06:16:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113629#M983519</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-08T06:16:27Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113630#M983520</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ok then, you could start with a select on BSIS and use the resulting data set to query BSEG.  But this would only help if the BSIS HKONT restriction gives you a much smaller set of data as a starting point for the BSEG select than you've already got in your FAE table.  And you'd have the disadvantage of two selects rather than one.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Personally, I'd stick with BSEG because it's got everything in it.  And I've never found that querying it on BUKRS / BELNR / GJAHR is that slow - unless you need to select a lot of data from it and (at the risk of repeating myself) large data quantities will slow down anything.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Jul 2008 09:24:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113630#M983520</guid>
      <dc:creator>christine_evans</dc:creator>
      <dc:date>2008-07-08T09:24:59Z</dc:date>
    </item>
    <item>
      <title>Re: performance tuning</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113631#M983521</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;Use FM FI_DOCUMENT_READ. pass belnr, bukrs and gjahr from bkpf table.&lt;/P&gt;&lt;P&gt;this fm gives a multiple rows for single row of data from bkpf. use it according to ur requirement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;my program runtime improved approx 30%.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;madhu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Jul 2008 09:27:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-tuning/m-p/4113631#M983521</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-08T09:27:26Z</dc:date>
    </item>
  </channel>
</rss>

