Register Login

Difference between Inner and Left Outer Join

Updated May 18, 2018

Hi All,

Inner Join vs Left Outer Join

Can anyone please explain how inner join works on two tables and on three tables?if possible with example?

Regards,

Pacchi


Comments

  • 23 Sep 2013 8:11 am Guest Best Answer
    Below is the example for joining three standard tables

    TABLES: mara, marc, mard.

    TYPES: BEGIN OF t_mara,
    matnr LIKE mara-matnr,
    END OF t_mara.

    DATA: it_mara TYPE STANDARD TABLE OF t_mara WITH HEADER LINE.

    SELECT mara~matnr
    INTO CORRESPONDING FIELDS OF TABLE it_mara
    FROM mara INNER JOIN marc ON ( mara~matnr = marc~matnr )
    INNER JOIN mard ON ( marc~matnr = mard~matnr AND marc~werks = mard~werks )
    * where mard~lgort = ' Storage Location Here you can use where class
    " and mara~matnr = ' Matnr.
  • 26 Sep 2013 3:21 am Parshuram MM Helpful Answer
    Excellent example...now i understood it completely.

×