<?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: Expensive SQL Statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/expensive-sql-statement/m-p/6235503#M1381314</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Also &lt;SPAN __jive_macro_name="thread" id="1283414"&gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;Thomas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 19 Oct 2009 12:41:49 GMT</pubDate>
    <dc:creator>ThomasZloch</dc:creator>
    <dc:date>2009-10-19T12:41:49Z</dc:date>
    <item>
      <title>Expensive SQL Statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/expensive-sql-statement/m-p/6235501#M1381312</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Guys, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have just received an email from our basis team where they said I am using an expensive SQL statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is a loop on a table of people with the following statement&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    SELECT * FROM catsdb INTO TABLE w_cats&lt;/P&gt;&lt;P&gt;      WHERE arbid EQ i_data-arbid&lt;/P&gt;&lt;P&gt;      AND   raufpl EQ i_data-aufpl&lt;/P&gt;&lt;P&gt;      AND   raplzl EQ i_data-aplzl&lt;/P&gt;&lt;P&gt;      AND   workdate IN s_wdate&lt;/P&gt;&lt;P&gt;      AND   status EQ '30'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it me or is this the quickest way possible?? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anyone think of a better way to do this??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks Experts&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Oct 2009 09:50:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/expensive-sql-statement/m-p/6235501#M1381312</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-10-19T09:50:51Z</dc:date>
    </item>
    <item>
      <title>Re: Expensive SQL Statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/expensive-sql-statement/m-p/6235502#M1381313</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;First of all, did you ever hear about indices? Please check whether there is an index (SE11) with has fields of your WHERE-condition.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=&amp;gt; if this is not the case the it will be slow, until an index is created.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Second, change the LOOP into a FOR ALL ENTRIES, don't forget to check whether the itab is initial.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Oct 2009 12:25:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/expensive-sql-statement/m-p/6235502#M1381313</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-10-19T12:25:31Z</dc:date>
    </item>
    <item>
      <title>Re: Expensive SQL Statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/expensive-sql-statement/m-p/6235503#M1381314</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Also &lt;SPAN __jive_macro_name="thread" id="1283414"&gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;Thomas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Oct 2009 12:41:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/expensive-sql-statement/m-p/6235503#M1381314</guid>
      <dc:creator>ThomasZloch</dc:creator>
      <dc:date>2009-10-19T12:41:49Z</dc:date>
    </item>
  </channel>
</rss>

