<?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: join query for three tables in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753165#M326493</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi again,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and use this view like any other database table you use in your select query to fetch data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;pankaj singh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 15 Dec 2006 07:03:24 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-12-15T07:03:24Z</dc:date>
    <item>
      <title>join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753157#M326485</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi i have got this query that is a join of two tables but i need join for three tables i need the extended query&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select a&lt;SUB&gt;authlname a&lt;/SUB&gt;authlnam a&lt;SUB&gt;authfname a&lt;/SUB&gt;authfnam a&lt;SUB&gt;isbn b&lt;/SUB&gt;title&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  from ( bsauthors as a inner join bsbook as b on a&lt;SUB&gt;isbn = b&lt;/SUB&gt;isbn )&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  into corresponding fields of table books&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  where a&lt;SUB&gt;authlname like authorlname or a&lt;/SUB&gt;authfname like authorfname&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  order by a&lt;SUB&gt;authlname a&lt;/SUB&gt;authfname a~isbn.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 06:42:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753157#M326485</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T06:42:19Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753158#M326486</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;select a&lt;SUB&gt;authlname a&lt;/SUB&gt;authlnam a&lt;SUB&gt;authfname a&lt;/SUB&gt;authfnam a&lt;SUB&gt;isbn b&lt;/SUB&gt;title&lt;/P&gt;&lt;P&gt;c~&amp;lt;fieldname&amp;gt;&lt;/P&gt;&lt;P&gt;from bsauthors as a inner join bsbook as b on a&lt;SUB&gt;isbn = b&lt;/SUB&gt;isbn &lt;/P&gt;&lt;P&gt;                              inner join &amp;lt;dbtab&amp;gt; as c on a&lt;SUB&gt;&amp;lt;fieldname&amp;gt; = &amp;lt;C&lt;/SUB&gt;FIELDNAME&amp;gt;&lt;/P&gt;&lt;P&gt;into corresponding fields of table books&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;where a&lt;SUB&gt;authlname like authorlname or a&lt;/SUB&gt;authfname like authorfname&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;order by a&lt;SUB&gt;authlname a&lt;/SUB&gt;authfname a~isbn. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REGARDS&lt;/P&gt;&lt;P&gt;SHIBA DUTTA&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 06:44:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753158#M326486</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T06:44:51Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753159#M326487</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Pavan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is not right practise to join three tables using ABAP code.&lt;/P&gt;&lt;P&gt;For better performance create a view and write a query.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1) Create a database view for 3 tables.&lt;/P&gt;&lt;P&gt;2) Write a select query on the database view.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Bhupal Reddy&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 06:51:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753159#M326487</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T06:51:09Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753160#M326488</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;its not recommended that u go for three tables inner join for performance issue&lt;/P&gt;&lt;P&gt;better create a datavbase view.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;pankaj singh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 06:51:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753160#M326488</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T06:51:46Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753161#M326489</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mr. Pankaj singh i'll follow your instructions in creating a new database view but as i'm new to this ABAP i dont know how to create a new data base view so that i can create that and it may be usefull to solve my problem completely&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 06:56:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753161#M326489</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T06:56:33Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753162#M326490</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Its not advisable to join three tables together and secondly, use GROUP BY instead of ORDER BY.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Shehryar Dahar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 06:59:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753162#M326490</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T06:59:36Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753163#M326491</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Pavan,&lt;/P&gt;&lt;P&gt; Go to transaction SE11, select the option view and enter a view name and click on Create. Select database view from the options available and click on Copy.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Enter a description for the view and in the Tables column, enter a table name and click on the Relationships button. All the related tables for the table entered will be displayed. Select the tables that you need to join and click on Copy.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Select the fields that you need from View flds tab and enter any conditions in the Selection Conditions tab and activate your view.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Manoj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 07:00:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753163#M326491</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T07:00:29Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753164#M326492</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;to create a database view -&lt;/P&gt;&lt;P&gt;goto se11&lt;/P&gt;&lt;P&gt;select view radiobutton - give a name -create&lt;/P&gt;&lt;P&gt;select database view-enter&lt;/P&gt;&lt;P&gt;give the description&lt;/P&gt;&lt;P&gt;in tables filed give all the tables one under the other-check all these and click on relationship at the down&lt;/P&gt;&lt;P&gt;it will show the relations betn the tables select all of them and it will come at right hand side join conditions &lt;/P&gt;&lt;P&gt;goto next tab-view fields -select the fields out of all the tables including primary keys which you want to display &lt;/P&gt;&lt;P&gt;save and activate it.&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;pankaj singh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 07:02:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753164#M326492</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T07:02:00Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753165#M326493</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi again,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and use this view like any other database table you use in your select query to fetch data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;pankaj singh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 07:03:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753165#M326493</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T07:03:24Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753166#M326494</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mr. Manoj &amp;amp; Pankaj &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i had proceeded in your instructions but after declaring the three tables(EKKO,EKBE,LFA1) in the tables column it was giving the relation only for the table which i had defined in the last of the tables column &lt;/P&gt;&lt;P&gt;i mean if i had declared the tables in this order&lt;/P&gt;&lt;P&gt;EKBE&lt;/P&gt;&lt;P&gt;EKKO&lt;/P&gt;&lt;P&gt;LFA1&lt;/P&gt;&lt;P&gt;then it was displaying only the tables related with LFA1 but not with other tables this is the case in every time i enter the tables into the tables column but i want the relation for all the three&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 07:42:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753166#M326494</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T07:42:23Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753167#M326495</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mr. Manoj &amp;amp; Pankaj &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i had proceeded in your instructions but after declaring the three tables(EKKO,EKBE,LFA1) in the tables column it was giving the relation only for the table which i had defined in the last of the tables column &lt;/P&gt;&lt;P&gt;i mean if i had declared the tables in this order&lt;/P&gt;&lt;P&gt;EKBE&lt;/P&gt;&lt;P&gt;EKKO&lt;/P&gt;&lt;P&gt;LFA1&lt;/P&gt;&lt;P&gt;then it was displaying only the tables related with LFA1 but not with other tables this is the case in every time i enter the tables into the tables column but i want the relation for all the three&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 07:42:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753167#M326495</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T07:42:49Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753168#M326496</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi pavan&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Plz try the following querry for joins on three tables :&lt;/P&gt;&lt;P&gt;" Customize it to ur requirements and tablenames&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Parameters : b type mara-matnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select x&lt;SUB&gt;matnr x&lt;/SUB&gt;mtart x&lt;SUB&gt;matkl y&lt;/SUB&gt;werks y&lt;SUB&gt;lgort z&lt;/SUB&gt;maktx&lt;/P&gt;&lt;P&gt; into corresponding fields of table itab&lt;/P&gt;&lt;P&gt;     from (  ( mara as x inner join mard as y on x&lt;SUB&gt;matnr = y&lt;/SUB&gt;matnr )&lt;/P&gt;&lt;P&gt;inner join makt as z on x&lt;SUB&gt;matnr = z&lt;/SUB&gt;matnr ) where x~matnr = a and&lt;/P&gt;&lt;P&gt;y~werks&lt;/P&gt;&lt;P&gt; = b .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Plz see that there is atleast one field common between the three tables u want to use.&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;Pankaj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 07:55:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753168#M326496</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T07:55:09Z</dc:date>
    </item>
    <item>
      <title>Re: join query for three tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753169#M326497</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mr. Pankaj i have created a database view on your instructions it was executed with small warnings but the values in that tables are not transfered to this database view while activating it was showing some warnings and after that i had tried to execute that i tried see the values in that but there are no values in the database view so what to do know please give me any suggestions&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Dec 2006 12:25:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/join-query-for-three-tables/m-p/1753169#M326497</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-15T12:25:07Z</dc:date>
    </item>
  </channel>
</rss>

