<?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: Select Stmt problem in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332346#M1228655</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;comming to performance better to use views ,it gives better performance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;jaya&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 02 Mar 2009 16:49:37 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-03-02T16:49:37Z</dc:date>
    <item>
      <title>Select Stmt problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332343#M1228652</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i am using following code to get FI accounting doc and year. but it is taking around 5 min to execute this select stmt can any one suggest me to improve the performance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  if not i_rseg[] is initial.&lt;/P&gt;&lt;P&gt;    select belnr&lt;/P&gt;&lt;P&gt;          gjahr&lt;/P&gt;&lt;P&gt;           budat&lt;/P&gt;&lt;P&gt;           awkey&lt;/P&gt;&lt;P&gt;           from bkpf&lt;/P&gt;&lt;P&gt;           into table i_bkpf&lt;/P&gt;&lt;P&gt;           for all entries in i_rseg&lt;/P&gt;&lt;P&gt;          where bukrs = i_rseg-bukrs&lt;/P&gt;&lt;P&gt;          and awkey = i_rseg-awkey.&lt;/P&gt;&lt;P&gt;  endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;there are around 15000 entries exist in the table which are related to select query.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanking you ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;srujan.p&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Mar 2009 16:34:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332343#M1228652</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-03-02T16:34:56Z</dc:date>
    </item>
    <item>
      <title>Re: Select Stmt problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332344#M1228653</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) Create a view for that table , or&lt;/P&gt;&lt;P&gt;2) Check for any existence of duplicate key valued entries in the internal table&lt;/P&gt;&lt;P&gt;delete them, because you are using &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;for all entries in itab&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;, or&lt;/P&gt;&lt;P&gt;3) If you don't need all the 15000 entries and you can get your work done with &lt;/P&gt;&lt;P&gt;a minimal number of values then use the statement &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;up to N rows&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;with your select query this way, you can improve the performance&lt;/P&gt;&lt;P&gt;and also hit the database only once in the entire operation&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Sharath&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Mar 2009 16:44:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332344#M1228653</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-03-02T16:44:02Z</dc:date>
    </item>
    <item>
      <title>Re: Select Stmt problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332345#M1228654</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You have to add AWTYP to the WHERE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Mar 2009 16:46:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332345#M1228654</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-03-02T16:46:59Z</dc:date>
    </item>
    <item>
      <title>Re: Select Stmt problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332346#M1228655</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;comming to performance better to use views ,it gives better performance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;jaya&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Mar 2009 16:49:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332346#M1228655</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-03-02T16:49:37Z</dc:date>
    </item>
    <item>
      <title>Re: Select Stmt problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332347#M1228656</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi is there any standard view for that, i did'nt used that concept, can you explain me how to do that.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Mar 2009 16:55:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332347#M1228656</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-03-02T16:55:35Z</dc:date>
    </item>
    <item>
      <title>Re: Select Stmt problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332348#M1228657</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; comming to performance better to use views ,it gives better performance.&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Why do you say that? The problem here is with the index.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Mar 2009 16:59:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332348#M1228657</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-03-02T16:59:12Z</dc:date>
    </item>
    <item>
      <title>Re: Select Stmt problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332349#M1228658</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;Over here I am trying to concatenate Rseg-Belnr, Rseg-Gjahr and pass this value to Bkpf-Awkey.&lt;/P&gt;&lt;P&gt;I require the entries of FI Doc data. And this is the place where my performance is affected badly!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any inputs on this?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Mar 2009 17:00:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332349#M1228658</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-03-02T17:00:01Z</dc:date>
    </item>
    <item>
      <title>Re: Select Stmt problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332350#M1228659</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; &lt;/P&gt;&lt;P&gt;&amp;gt; Over here I am trying to concatenate Rseg-Belnr, Rseg-Gjahr and pass this value to Bkpf-Awkey.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;I understand that. You are trying to use index BKPF~4 (Index by application type and key). But here AWTYP is the first non-client field of the index, so you have to include it in the WHERE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Mar 2009 17:07:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332350#M1228659</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-03-02T17:07:19Z</dc:date>
    </item>
    <item>
      <title>Re: Select Stmt problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332351#M1228660</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;BKPF have the index 8 by the field AWKEY, try this index ... without using the field BUKRS&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Mar 2009 18:29:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select-stmt-problem/m-p/5332351#M1228660</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-03-02T18:29:48Z</dc:date>
    </item>
  </channel>
</rss>

