<?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: inner and outer join in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721743#M896010</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi, &lt;/P&gt;&lt;P&gt;you can use inner join where you want only common data from two or more tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and outer join when you want common as well as all data from one table.&lt;/P&gt;&lt;P&gt;e.g if you apply left outer joiin on table1 and table 2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;then you will get common data from both table and remaning lines fron table1 . in data which are not common will have null values corresponding to table2 entries.&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;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reward if useful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 23 Apr 2008 06:28:36 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-04-23T06:28:36Z</dc:date>
    <item>
      <title>inner and outer join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721740#M896007</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi experts,&lt;/P&gt;&lt;P&gt;   when we used inner join and outer join ,then where the data is filtred e.g. application server ,database or presentation?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   thaks in advanced.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Apr 2008 06:11:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721740#M896007</guid>
      <dc:creator>former_member549415</dc:creator>
      <dc:date>2008-04-23T06:11:34Z</dc:date>
    </item>
    <item>
      <title>Re: inner and outer join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721741#M896008</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The data that can be selected with a view depends primarily on whether the view implements an inner join or an outer join. With an inner join, you only get the records of the cross-product for which there is an entry in all tables used in the view. With an outer join, records are also selected for which there is no entry in some of the tables used in the view.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The set of hits determined by an inner join can therefore be a subset of the hits determined with an outer join.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Database views implement an inner join. The database therefore only provides those records for which there is an entry in all the tables used in the view. Help views and maintenance views, however, implement an outer join.&lt;/P&gt;&lt;P&gt;Follow this link:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_erp2005/helpdata/en/cf/21ec77446011d189700000e8322d00/frameset.htm" target="test_blank"&gt;http://help.sap.com/saphelp_erp2005/helpdata/en/cf/21ec77446011d189700000e8322d00/frameset.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for example below are the 2 tables and their values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A B&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1000 1000 A&lt;/P&gt;&lt;P&gt;2000 1000 B&lt;/P&gt;&lt;P&gt;3000 3000 C&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;inner join will fetch the common records as like follows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1000 A&lt;/P&gt;&lt;P&gt;1000 B&lt;/P&gt;&lt;P&gt;3000 C&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If it is the case of outer join the output will be&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1000 A&lt;/P&gt;&lt;P&gt;1000 B&lt;/P&gt;&lt;P&gt;2000&lt;/P&gt;&lt;P&gt;3000 C&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Anon&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Apr 2008 06:25:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721741#M896008</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-23T06:25:30Z</dc:date>
    </item>
    <item>
      <title>Re: inner and outer join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721742#M896009</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;  You will be using INNER and OUTER joins in a SELECT query.  SELECT query always refers to Data base only.  So INNER and OUTER joins always filter the data at Data base level only.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks &amp;amp; regards&lt;/P&gt;&lt;P&gt;Kishore Kumar Maram&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Apr 2008 06:25:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721742#M896009</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-23T06:25:34Z</dc:date>
    </item>
    <item>
      <title>Re: inner and outer join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721743#M896010</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi, &lt;/P&gt;&lt;P&gt;you can use inner join where you want only common data from two or more tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and outer join when you want common as well as all data from one table.&lt;/P&gt;&lt;P&gt;e.g if you apply left outer joiin on table1 and table 2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;then you will get common data from both table and remaning lines fron table1 . in data which are not common will have null values corresponding to table2 entries.&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;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reward if useful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Apr 2008 06:28:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721743#M896010</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-23T06:28:36Z</dc:date>
    </item>
    <item>
      <title>Re: inner and outer join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721744#M896011</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 go thru this. u will get clear idea.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;U&gt;table - &lt;STRONG&gt;emp&lt;/STRONG&gt;&lt;/U&gt; &lt;/P&gt;&lt;P&gt;empno name&lt;/P&gt;&lt;P&gt;a          sasi&lt;/P&gt;&lt;P&gt;b          xxx &lt;/P&gt;&lt;P&gt;c          yyy&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;U&gt;table- &lt;STRONG&gt;sal&lt;/STRONG&gt;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;empno salary&lt;/P&gt;&lt;P&gt;a         1000&lt;/P&gt;&lt;P&gt;b         2000&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Inner join&lt;/P&gt;&lt;P&gt;****************&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;select e~empno e~name 
s~sal 
into table int_table
from emp as e
inner join sal
on 
e~empno = s~empno.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you made inner join between table a and b by emp no &lt;/P&gt;&lt;P&gt;the selection retrives only if the condition satisfy the output will be&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;a sasi 1000&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;b xxx 2000&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Outer join&lt;/P&gt;&lt;P&gt;*************************&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;select e~empno e~name 
s~sal into table  int_table
from emp as e
LEFT OUTER JOIN sal
on 
e~empno = s~empno.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you made outer join (left /right ) the left table kept as it is the &lt;/P&gt;&lt;P&gt;if the condition satisfy the right table entries will fetch else leave it blank&lt;/P&gt;&lt;P&gt;the output will be&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;a sasi a 1000&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;b xxx b 2000&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;c yyy&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rgds&lt;/P&gt;&lt;P&gt;Anversha&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Apr 2008 06:29:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721744#M896011</guid>
      <dc:creator>anversha_s</dc:creator>
      <dc:date>2008-04-23T06:29:52Z</dc:date>
    </item>
    <item>
      <title>Re: inner and outer join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721745#M896012</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;STRONG&gt;inner join&lt;/STRONG&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The data that can be selected with a view depends primarily on whether the view implements an inner join or an outer join. With an inner join, you only get the records of the cross-product for which there is an entry in all tables used in the view. With an outer join, records are also selected for which there is no entry in some of the tables used in the view.  The set of hits determined by an inner join can therefore be a subset of the hits determined with an outer join. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Example for Inner join:&lt;/STRONG&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT A&lt;SUB&gt;EBELN A&lt;/SUB&gt;LIFNR A&lt;SUB&gt;KNUMV B&lt;/SUB&gt;EBELP B&lt;SUB&gt;NETWR B&lt;/SUB&gt;NETPR B&lt;SUB&gt;WERKS B&lt;/SUB&gt;MATNR &lt;/P&gt;&lt;P&gt;  L&lt;SUB&gt;NAME1 L&lt;/SUB&gt;NAME2 &lt;/P&gt;&lt;P&gt;  FROM EKKO AS A &lt;/P&gt;&lt;P&gt;  INNER JOIN EKPO AS B ON A&lt;SUB&gt;EBELN = B&lt;/SUB&gt;EBELN &lt;/P&gt;&lt;P&gt;  INNER JOIN LFA1 AS L ON L&lt;SUB&gt;LIFNR = A&lt;/SUB&gt;LIFNR &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;INNER JOIN EKKN AS C ON C&lt;SUB&gt;EBELN = A&lt;/SUB&gt;EBELN &lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  INTO CORRESPONDING FIELDS OF TABLE itab &lt;/P&gt;&lt;P&gt;  WHERE B~BUKRS = 'company code' . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Left outer join&lt;/STRONG&gt; &lt;/P&gt;&lt;P&gt;Usually, when defining InfoSets, the objects are linked via inner join operators. However, you can also use left outer joins.  Inner join and left outer join are only different in the situation where one of the involved tables does not contain any suitable record which meets the join conditions. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With an inner join (table 1 inner join table 2), no record is included in the result set in this case. However, this means that the corresponding record from tables 1 is not considered in the results set.                                         &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With an left outer join (table 1 left outer join table2), exactly one record is included in the results set in this case´. In this record, the fields from table 1 contain the values of the record from table 1 and the fields from table 2 are all filled with the initial value.    &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example of left outer join: &lt;/P&gt;&lt;P&gt;DATA: CUSTOMER TYPE SCUSTOM,  &lt;/P&gt;&lt;P&gt;      BOOKING  TYPE SBOOK.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT SCUSTOM&lt;SUB&gt;NAME SCUSTOM&lt;/SUB&gt;POSTCODE SCUSTOM~CITY  &lt;/P&gt;&lt;P&gt;       SBOOK&lt;SUB&gt;FLDATE SBOOK&lt;/SUB&gt;CARRID SBOOK&lt;SUB&gt;CONNID SBOOK&lt;/SUB&gt;BOOKID  &lt;/P&gt;&lt;P&gt;       INTO (CUSTOMER-NAME, CUSTOMER-POSTCODE, CUSTOMER-CITY,  &lt;/P&gt;&lt;P&gt;             BOOKING-FLDATE, BOOKING-CARRID, BOOKING-CONNID,  &lt;/P&gt;&lt;P&gt;             BOOKING-BOOKID)  &lt;/P&gt;&lt;P&gt;       FROM SCUSTOM LEFT OUTER JOIN SBOOK  &lt;/P&gt;&lt;P&gt;         ON SCUSTOM&lt;SUB&gt;ID = SBOOK&lt;/SUB&gt;CUSTOMID AND  &lt;/P&gt;&lt;P&gt;            SBOOK~FLDATE = '20081015'  &lt;/P&gt;&lt;P&gt;       ORDER BY SCUSTOM&lt;SUB&gt;NAME SBOOK&lt;/SUB&gt;FLDATE.  &lt;/P&gt;&lt;P&gt;  WRITE: / CUSTOMER-NAME, CUSTOMER-POSTCODE, CUSTOMER-CITY,  &lt;/P&gt;&lt;P&gt;           BOOKING-FLDATE, BOOKING-CARRID, BOOKING-CONNID,  &lt;/P&gt;&lt;P&gt;           BOOKING-BOOKID.  &lt;/P&gt;&lt;P&gt;ENDSELECT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Apr 2008 06:39:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721745#M896012</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-23T06:39:18Z</dc:date>
    </item>
    <item>
      <title>Re: inner and outer join</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721746#M896013</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Somnath,&lt;/P&gt;&lt;P&gt;The data is filtered at the database only and not at the presentation layer or applicatiion layer.Only the filtered data is transferred to the application layer.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pls refer the following link for any clarifications you might have&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_47x200/helpdata/en/fc/eb3976358411d1829f0000e829fbfe/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_47x200/helpdata/en/fc/eb3976358411d1829f0000e829fbfe/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Pls reward points if found useful..&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Apr 2008 06:44:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/inner-and-outer-join/m-p/3721746#M896013</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-23T06:44:33Z</dc:date>
    </item>
  </channel>
</rss>

