<?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: problem with select statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049028#M1173608</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Would recommend to use &lt;/P&gt;&lt;P&gt;OPEN CURSOR SELECT ...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;FETCH NEXT CURSOR.... PACKAGE SIZE 1000.&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is better approach to avoid memory issue.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 08 Jan 2009 07:06:50 GMT</pubDate>
    <dc:creator>Sathish</dc:creator>
    <dc:date>2009-01-08T07:06:50Z</dc:date>
    <item>
      <title>problem with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049026#M1173606</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;I am using select statement on IMRG table with measuring point field in where clause. This select included in another select endselect which is a requirement and cannot be avoided.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There already exist a secondary index on this field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Problem is when i run the program in debugging mode, the select statement works fine but it dumps with time limit error when i run it directly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kindly help us what could be done to overcome this issue.&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;Gurmukh singh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Jan 2009 02:18:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049026#M1173606</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-08T02:18:50Z</dc:date>
    </item>
    <item>
      <title>Re: problem with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049027#M1173607</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;As the select  statement (IMRG) you are using in SELECT ENDSELECT, the problem might be a buffering issue and going to dump.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So in the SELECT ENDSELECT use the PACKAGE option which will read the data in packets and executes the inbetween logic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Suppose you are getting a 10000 records at one shot using SELECT ENDSELECT, PACKAGE option,&lt;/P&gt;&lt;P&gt;process this 10000 records wherever used and finally clear this 10000 records.&lt;/P&gt;&lt;P&gt;The SELECT ENDSELECT will fetch next 10000 if exists and continues processing. &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;Chitti babu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Jan 2009 04:08:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049027#M1173607</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-08T04:08:52Z</dc:date>
    </item>
    <item>
      <title>Re: problem with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049028#M1173608</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Would recommend to use &lt;/P&gt;&lt;P&gt;OPEN CURSOR SELECT ...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;FETCH NEXT CURSOR.... PACKAGE SIZE 1000.&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is better approach to avoid memory issue.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Jan 2009 07:06:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049028#M1173608</guid>
      <dc:creator>Sathish</dc:creator>
      <dc:date>2009-01-08T07:06:50Z</dc:date>
    </item>
    <item>
      <title>Re: problem with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049029#M1173609</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;I suppose the dump is due to long execution time rather than memory issues . You  should use PACKAGE size in case of memory issues rather that Long execution time. Please paste your  select query so that we can have a look. Also let us know what is the total no of records in the table to get the size of table.&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;Raj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Jan 2009 07:20:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049029#M1173609</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-08T07:20:08Z</dc:date>
    </item>
    <item>
      <title>Re: problem with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049030#M1173610</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;due to performace reason u r program is going to short dump,try to avoide the select and endselect ,if u writing with in the loop for execution it take more time .use another select statement like select single r select up to rows .....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;past u select statement ...&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;Regards,&lt;/P&gt;&lt;P&gt;Madhu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Jan 2009 08:41:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049030#M1173610</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-08T08:41:05Z</dc:date>
    </item>
    <item>
      <title>Re: problem with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049031#M1173611</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 cursors, ur problem will be resolved. This procedure can avoid  using select statements within select-endselect which is performance slow process.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reason for dump is, you might have fetching huge data from select end select and passing it to inner select using for all entreis, due to memory overflow reason, your program might going to dump.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please use cursors to avoid this memory problems.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OPEN CURSOR SELECT ...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;FETCH NEXT CURSOR.... PACKAGE SIZE 1000.&lt;/P&gt;&lt;P&gt;if sy-sybrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;exit.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Jan 2009 13:19:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049031#M1173611</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-08T13:19:01Z</dc:date>
    </item>
    <item>
      <title>Re: problem with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049032#M1173612</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;@RAM RAM see other positing&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;same here:&lt;/P&gt;&lt;P&gt;&amp;gt; with time limit error when i run it directly&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is too slow.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Change in batch and you are done.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or try to optimze it. But if it runs onyl very rarely, then batch is the simpler option.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Siegfried&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Jan 2009 15:32:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049032#M1173612</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-08T15:32:20Z</dc:date>
    </item>
    <item>
      <title>Re: problem with select statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049033#M1173613</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Guru,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will suggest you not to use endselect.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select and insert into table itab.&lt;/P&gt;&lt;P&gt;after that you can use read with binary search and loop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please send your code so that i can modify accordingly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i was also getting same issues but i resolved.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sujeet&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Jan 2009 06:04:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-select-statement/m-p/5049033#M1173613</guid>
      <dc:creator>SujeetMishra</dc:creator>
      <dc:date>2009-01-09T06:04:00Z</dc:date>
    </item>
  </channel>
</rss>

