<?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: Read statment issue in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848118#M1319190</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Karthik,&lt;/P&gt;&lt;P&gt;             The loop is not allowed since the data volume is huge.The Read stmt is used to identfiy the data base table dynamically (which table we need to select more than on DB table i neeed to do select based on the interies-field in itab).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So only iam searching for new options which will give better performance...&lt;/P&gt;&lt;P&gt;&lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sri&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 17 Jun 2009 03:14:59 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-06-17T03:14:59Z</dc:date>
    <item>
      <title>Read statment issue</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848114#M1319186</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi ,&lt;/P&gt;&lt;P&gt;        My &lt;STRONG&gt;itab&lt;/STRONG&gt; internal table is having 10 reocrds of kotabnr = '001' the below code i have written &lt;/P&gt;&lt;P&gt;will go for all 10 record or only one record.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if  read will get only one record, means how best i can write the code to get 10 records from intrnal table &lt;U&gt;&lt;STRONG&gt;without LOOP&lt;/STRONG&gt;&lt;/U&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;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------------------------------------------------------" /&gt;&lt;P&gt;READ TABLE Itab WITH KEY kotabnr = '001' TRANSPORTING NO FIELDS.&lt;/P&gt;&lt;P&gt;      IF sy-subrc EQ 0.&lt;/P&gt;&lt;P&gt;     &lt;/P&gt;&lt;P&gt; Select &lt;/P&gt;&lt;P&gt;                   KBSTAT&lt;/P&gt;&lt;P&gt;                   KNUMH&lt;/P&gt;&lt;P&gt;            from A912 into table i_a912 where knumh = ls_headr_item-knumh.&lt;/P&gt;&lt;P&gt;&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;Regards,&lt;/P&gt;&lt;P&gt;Sri&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2009 02:00:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848114#M1319186</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-06-17T02:00:57Z</dc:date>
    </item>
    <item>
      <title>Re: Read statment issue</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848115#M1319187</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Read table command reads only one record ,that means it will go only one time,if you need multiple times then use loop and endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;P&gt;Seshu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2009 02:08:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848115#M1319187</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-06-17T02:08:34Z</dc:date>
    </item>
    <item>
      <title>Re: Read statment issue</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848116#M1319188</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;So whats the purpose of that READ statement, why you don't want to go for LOOP. If possible try to use For All Entries Statement in Select query, that will increase performance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Karthik D&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2009 03:01:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848116#M1319188</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-06-17T03:01:38Z</dc:date>
    </item>
    <item>
      <title>Re: Read statment issue</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848117#M1319189</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sriram,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With read you can perform only these operations....&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;READ&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Read an internal table&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;STRONG&gt;- READ TABLE itab FROM wa [additions].&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;STRONG&gt;- READ TABLE itab WITH TABLE KEY k1 = v1 ...kn = vn [additions].&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;- READ TABLE itab WITH KEY k1 = v1 ...kn = vn [BINARY SEARCH] [additions].&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;STRONG&gt;- READ TABLE itab INDEX i [additions].&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;STRONG&gt;- Obsolete Variants&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Read a program&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;STRONG&gt;- READ REPORT prog INTO itab.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Read text elements&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;STRONG&gt;- READ TEXTPOOL prog ...INTO itab ...LANGUAGE lg.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Read from a file&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;STRONG&gt;- READ DATASET dsn INTO f.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Read a database table&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;STRONG&gt;- READ TABLE dbtab.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Dileep .C&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2009 03:10:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848117#M1319189</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-06-17T03:10:23Z</dc:date>
    </item>
    <item>
      <title>Re: Read statment issue</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848118#M1319190</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Karthik,&lt;/P&gt;&lt;P&gt;             The loop is not allowed since the data volume is huge.The Read stmt is used to identfiy the data base table dynamically (which table we need to select more than on DB table i neeed to do select based on the interies-field in itab).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So only iam searching for new options which will give better performance...&lt;/P&gt;&lt;P&gt;&lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sri&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2009 03:14:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848118#M1319190</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-06-17T03:14:59Z</dc:date>
    </item>
    <item>
      <title>Re: Read statment issue</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848119#M1319191</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;Please use 'FOR ALL ENTRIES' in your select statement..... Read will always return only one instance...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2009 03:47:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848119#M1319191</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-06-17T03:47:59Z</dc:date>
    </item>
    <item>
      <title>Re: Read statment issue</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848120#M1319192</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;The other posters are right. You can't use READ to get more than one entry. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The best thing you can use if you don't want to use loop is to use FOR ALL ENTRIES inside your SELECT statement:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;Select
KBSTAT
KNUMH
from A912 into table i_a912 FOR ALL ENTRIES IN internal_table where knumh = internal_table-knumh&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2009 10:10:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/read-statment-issue/m-p/5848120#M1319192</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-06-17T10:10:59Z</dc:date>
    </item>
  </channel>
</rss>

