<?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: in prob -need solution...... in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805349#M345711</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;SELECT KUNNR VKORG PARVW FROM KNVP INTO TABLE T_KNVP&lt;/P&gt;&lt;P&gt;FOR ALL ENTRIES IN T_KNA1&lt;/P&gt;&lt;P&gt;WHERE KUNNR = T_KNA1-KUNNR. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let, before this statement t_kna1 have some data of 100 records of kunnr (1 to 100).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This select statement reads the KUNNR VKORG PARVW fields from the table knvp into t_knvp for all the entries in the table t_kna1(ie, from record 1 to 100).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;read it carefully. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanx.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 06 Dec 2006 13:46:54 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-12-06T13:46:54Z</dc:date>
    <item>
      <title>in prob -need solution......</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805344#M345706</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Anybody couls tell me what the exact meaning of this syntax. here for all entrien in t_kna1 mean what?. confuse a bit....plz help me....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT KUNNR VKORG PARVW FROM KNVP INTO TABLE T_KNVP&lt;/P&gt;&lt;P&gt;        FOR  ALL ENTRIES IN T_KNA1&lt;/P&gt;&lt;P&gt;        WHERE KUNNR = T_KNA1-KUNNR.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Dec 2006 06:50:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805344#M345706</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-05T06:50:42Z</dc:date>
    </item>
    <item>
      <title>Re: in prob -need solution......</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805345#M345707</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For each entry  T_KNA1 internal tables it gets the data from KNVP and dumps that into T_KNVP tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is used to avoid firing select statements inside a internal table loop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ravi&lt;/P&gt;&lt;P&gt;Note - Please mark all the helpful answers&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Dec 2006 06:55:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805345#M345707</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-05T06:55:17Z</dc:date>
    </item>
    <item>
      <title>Re: in prob -need solution......</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805346#M345708</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Abhay&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Internal Table: T_KNA1 holds the records of all customers.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The statement is to extract the Customer Partners from KNVP for each of the customer in internal table T_KNA1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind Regards&lt;/P&gt;&lt;P&gt;Eswar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Dec 2006 06:56:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805346#M345708</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-05T06:56:28Z</dc:date>
    </item>
    <item>
      <title>Re: in prob -need solution......</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805347#M345709</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;This code will fetch the values of the fields KUNNR,VKORG,PARVW from database table KNVP and then places the records in internal table T_KNVP.But the records from KNVP are selected if there exists a corresponding entry in internal table T_KNA1 for KUNNR value.The specified select statement should be in if sy-subrc eq 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kindly reward points by clikcing the star on the left fo reply,if it helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Dec 2006 07:01:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805347#M345709</guid>
      <dc:creator>jayanthi_jayaraman</dc:creator>
      <dc:date>2006-12-05T07:01:32Z</dc:date>
    </item>
    <item>
      <title>Re: in prob -need solution......</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805348#M345710</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The basic reason for using 'FOR ALL ENTRIES' is to avoid a full scan of database search on the table KNVP which would cause a performance issue.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For the first database search from KNA1 we are making a full scan of the database table. And by using the 'FOR ALL ENTRIES' we are narrowing our database search to only those found satisfying in the table T_KNA1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Before firing a select with the construct 'FOR ALL ENTRIES IN T_KAN1' try checking if the the table T_KNA1 is not initial, otherwise it would result in all the customer numbers from KNVP getting selected which would be a performace issueand also illogical at times. Please note all these are done to make the search more efficient and increase the performance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note: Please give a point if you are convinced&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Dec 2006 07:17:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805348#M345710</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-05T07:17:40Z</dc:date>
    </item>
    <item>
      <title>Re: in prob -need solution......</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805349#M345711</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;SELECT KUNNR VKORG PARVW FROM KNVP INTO TABLE T_KNVP&lt;/P&gt;&lt;P&gt;FOR ALL ENTRIES IN T_KNA1&lt;/P&gt;&lt;P&gt;WHERE KUNNR = T_KNA1-KUNNR. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let, before this statement t_kna1 have some data of 100 records of kunnr (1 to 100).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This select statement reads the KUNNR VKORG PARVW fields from the table knvp into t_knvp for all the entries in the table t_kna1(ie, from record 1 to 100).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;read it carefully. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanx.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Dec 2006 13:46:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805349#M345711</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-06T13:46:54Z</dc:date>
    </item>
    <item>
      <title>Re: in prob -need solution......</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805350#M345712</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Abhay Singh&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Syntax &lt;/P&gt;&lt;P&gt;... FOR ALL ENTRIES IN itab WHERE ... col operator itab-comp ... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect &lt;/P&gt;&lt;P&gt;If the addition FOR ALL ENTRIES is specified before the language element WHERE, then the components comp of the internal table itab can be used as operands when comparing with relational operators. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The internal table itab must have a structured line type and the component comp must be compatible with the column col. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The logical expression sql_cond of the WHERE condition can comprise various logical expressions by using AND and OR. However, if FOR ALL ENTRIES is specified, there must be at least one Comparison with a column of the internal table itab, which can be specified either statistically or dynamically (Release 6.40 and higher). In a statement with a SELECTstatement with FOR ALL ENTRIES, the addition ORDER BY can only be used with the addition PRIMARY KEY. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The whole logical expression sql_cond is evaluated for each individual line of the internal table itab. The resulting set of the SELECT statement is the union of the resulting sets from the individual evaluations. Duplicate lines are automatically removed from the resulting set. If the internal table itab is empty, the whole WHERE statement is ignored and all lines in the database are put in the resulting set. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Notes &lt;/P&gt;&lt;P&gt;In Release 6.10 and higher, the same internal table can be specified after FOR ALL ENTRIES and after INTO. &lt;/P&gt;&lt;P&gt;The addition FOR ALL ENTRIES is only possible before WHERE conditions of the SELECT statement. &lt;/P&gt;&lt;P&gt;Example &lt;/P&gt;&lt;P&gt;Exporting all flight data for a specified departure city. The relevant airlines and flight numbers are first put in an internal table entry_tab, which is evaluated in the WHERE condition of the subsquent SELECT statement. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PARAMETERS p_city TYPE spfli-cityfrom. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TYPES: BEGIN OF entry_tab_type, &lt;/P&gt;&lt;P&gt;         carrid TYPE spfli-carrid, &lt;/P&gt;&lt;P&gt;         connid TYPE spfli-connid, &lt;/P&gt;&lt;P&gt;       END OF entry_tab_type. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: entry_tab   TYPE TABLE OF entry_tab_type, &lt;/P&gt;&lt;P&gt;      sflight_tab TYPE SORTED TABLE OF sflight &lt;/P&gt;&lt;P&gt;                       WITH UNIQUE KEY carrid connid fldate. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT carrid connid &lt;/P&gt;&lt;P&gt;       FROM spfli &lt;/P&gt;&lt;P&gt;       INTO CORRESPONDING FIELDS OF TABLE entry_tab &lt;/P&gt;&lt;P&gt;       WHERE cityfrom = p_city. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT carrid connid fldate &lt;/P&gt;&lt;P&gt;       FROM sflight &lt;/P&gt;&lt;P&gt;       INTO CORRESPONDING FIELDS OF TABLE sflight_tab &lt;/P&gt;&lt;P&gt;       FOR ALL ENTRIES IN entry_tab &lt;/P&gt;&lt;P&gt;       WHERE carrid = entry_tab-carrid AND &lt;/P&gt;&lt;P&gt;             connid = entry_tab-connid.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Dec 2006 10:22:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/in-prob-need-solution/m-p/1805350#M345712</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-07T10:22:40Z</dc:date>
    </item>
  </channel>
</rss>

