<?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: Table Join in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303616#M791093</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi..&lt;/P&gt;&lt;P&gt;Alwayz remeber that the fields which you are using in WHERE condition should be Primary Key Fields.&lt;/P&gt;&lt;P&gt;Then only the statement will be efiicient.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you are not using Primary key field in WHERE condition, then you should use Secondory indexes in WHERE condition to improve the efficiency.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards &lt;/P&gt;&lt;P&gt;sandeep.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 25 Jan 2008 17:19:13 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-01-25T17:19:13Z</dc:date>
    <item>
      <title>Table Join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303612#M791089</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi ABAP Gurus,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have got the following scenario&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT A&lt;SUB&gt;FIELD1 A&lt;/SUB&gt;FIELD2 B&lt;SUB&gt;FIELD1 B&lt;/SUB&gt;FIELD2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;               FROM TABLE 1 AS A&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;               JOIN TABLE 2 AS B ON A&lt;SUB&gt;FIELD1 = B&lt;/SUB&gt;FIELD9&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;               WHERE A~FIELD1 IN S_OPT1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                    AND A~FIELD2 IN S_OPT2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                    AND B~FIELD2 IN S_OPT3&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                    AND B~FIELD3 IN S_OPT4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TABLE1 key is FIELD1 and FIELD2. TABLE2 key is FIELD1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When creating an index for TABLE2, should the index include the field used in the join I.E. FIELD9, FIELD2, FIELD3 or should it just contain FIELD 2 and FIELD3 from the where clause ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jan 2008 11:13:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303612#M791089</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-25T11:13:27Z</dc:date>
    </item>
    <item>
      <title>Re: Table Join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303613#M791090</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;It should just contain the fields used in your WHERE clause, also make sure the order is also the same.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Ranganath&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jan 2008 12:35:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303613#M791090</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-25T12:35:17Z</dc:date>
    </item>
    <item>
      <title>Re: Table Join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303614#M791091</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi Bhai,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;essentially, creation of indexes is very critical.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you must analyze/ensure the fields on which you are creating the index are optimum for the table or not. a transaction that helps you achieve this is DB05.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in this transaction, you enter the table name and field names on which you wish to create the index. the result of this is to show you how many unique entries can be found using these field criteria&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the more unique the results the better or more optimum the index would be&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;please consult basis for this ..... if you create an index on a table with fields which return approximately half the dtaabase table entries every time, i.e. create that large a cache buffer, you can imagine how bad the program performance would be ..... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;aditya&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jan 2008 13:15:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303614#M791091</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-25T13:15:41Z</dc:date>
    </item>
    <item>
      <title>Re: Table Join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303615#M791092</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are the tables standard SAP tables or custom tables? Are they updated in batch only or also online?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jan 2008 14:33:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303615#M791092</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-25T14:33:03Z</dc:date>
    </item>
    <item>
      <title>Re: Table Join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303616#M791093</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi..&lt;/P&gt;&lt;P&gt;Alwayz remeber that the fields which you are using in WHERE condition should be Primary Key Fields.&lt;/P&gt;&lt;P&gt;Then only the statement will be efiicient.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you are not using Primary key field in WHERE condition, then you should use Secondory indexes in WHERE condition to improve the efficiency.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards &lt;/P&gt;&lt;P&gt;sandeep.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jan 2008 17:19:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-join/m-p/3303616#M791093</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-01-25T17:19:13Z</dc:date>
    </item>
  </channel>
</rss>

