<?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: Using RANGE table in SELECT statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348543#M1992540</link>
    <description>&lt;P&gt;The maximal size of a SQL statement depends on your database. Perform some test if database manager cannot answer.&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;If your range contains only include records criteria (sign = 'I') you can split the range in smaller ones and load data in packet. (In this case removing duplicate records may be required)&lt;/LI&gt;&lt;LI&gt;If your range contains only a list of values (sign = 'I', option = 'EQ') you can use a simple FOR ALL ENTRIES option (Abap SQL will remove duplicates)&lt;/LI&gt;&lt;/UL&gt;</description>
    <pubDate>Tue, 19 Jan 2021 09:02:49 GMT</pubDate>
    <dc:creator>RaymondGiuseppi</dc:creator>
    <dc:date>2021-01-19T09:02:49Z</dc:date>
    <item>
      <title>Using RANGE table in SELECT statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348540#M1992537</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
  &lt;P&gt;I am getting a short dump -&amp;gt; Err.tmpo.ejec. DBSQL_STMNT_TOO_LARGE Excep. CX_SY_OPEN_SQL_DB&lt;/P&gt;
  &lt;P&gt;in the following code:&lt;/P&gt;
  &lt;P&gt;SELECT * FROM pcl2&lt;BR /&gt; INTO TABLE lt_pcl2&lt;BR /&gt; WHERE relid EQ 'B2'&lt;BR /&gt; AND srtfd IN rl_srtfd &amp;lt;------cause of the error&lt;BR /&gt; AND srtf2 EQ '00'.&lt;/P&gt;
  &lt;P&gt;The error occurs because the range table rl_srtfd has 32664 rows, which are too many to be processed in the SELECT statement.&lt;/P&gt;
  &lt;P&gt;I'm not sure what is the limit because I've tried the program with only 10000 rows in rl_srtfd and it didn't give a dump.&lt;/P&gt;
  &lt;P&gt;How should I proceed to solve this? How do I know the limit of the size of rl_srtfd?&lt;/P&gt;
  &lt;P&gt;Thank you all in advance.&lt;/P&gt;</description>
      <pubDate>Mon, 18 Jan 2021 17:56:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348540#M1992537</guid>
      <dc:creator>former_member3635</dc:creator>
      <dc:date>2021-01-18T17:56:07Z</dc:date>
    </item>
    <item>
      <title>Re: Using RANGE table in SELECT statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348541#M1992538</link>
      <description>&lt;P&gt;If your range contains so much values, the generated SQL statement is too long (&lt;A href="https://apps.support.sap.com/sap/support/knowledge/en/2317211"&gt;snote 2317211&lt;/A&gt;).&lt;/P&gt;&lt;P&gt;Easiest solution would be splitting your range in several ranges and run a SQL statement for each of those ranges (containing 1000-1500 values or so).&lt;/P&gt;&lt;P&gt;Depending on the how, where, why and when you could also try and find another solution and don't use ranges at all.&lt;/P&gt;</description>
      <pubDate>Mon, 18 Jan 2021 18:33:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348541#M1992538</guid>
      <dc:creator>Patrick_vN</dc:creator>
      <dc:date>2021-01-18T18:33:38Z</dc:date>
    </item>
    <item>
      <title>Re: Using RANGE table in SELECT statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348542#M1992539</link>
      <description>&lt;P&gt;If it works for 10.000 then keep that number and you should never have the issue again.&lt;/P&gt;</description>
      <pubDate>Tue, 19 Jan 2021 07:56:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348542#M1992539</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2021-01-19T07:56:09Z</dc:date>
    </item>
    <item>
      <title>Re: Using RANGE table in SELECT statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348543#M1992540</link>
      <description>&lt;P&gt;The maximal size of a SQL statement depends on your database. Perform some test if database manager cannot answer.&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;If your range contains only include records criteria (sign = 'I') you can split the range in smaller ones and load data in packet. (In this case removing duplicate records may be required)&lt;/LI&gt;&lt;LI&gt;If your range contains only a list of values (sign = 'I', option = 'EQ') you can use a simple FOR ALL ENTRIES option (Abap SQL will remove duplicates)&lt;/LI&gt;&lt;/UL&gt;</description>
      <pubDate>Tue, 19 Jan 2021 09:02:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348543#M1992540</guid>
      <dc:creator>RaymondGiuseppi</dc:creator>
      <dc:date>2021-01-19T09:02:49Z</dc:date>
    </item>
    <item>
      <title>Re: Using RANGE table in SELECT statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348544#M1992541</link>
      <description>&lt;P&gt;Thank you Patrick,&lt;/P&gt;&lt;P&gt;Another, less efficient, option would be to remove that condition and afterwards delete all undesired entries&lt;/P&gt;</description>
      <pubDate>Tue, 19 Jan 2021 09:59:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/using-range-table-in-select-statement/m-p/12348544#M1992541</guid>
      <dc:creator>former_member3635</dc:creator>
      <dc:date>2021-01-19T09:59:59Z</dc:date>
    </item>
  </channel>
</rss>

