leftJoin == LEFT OUTER JOIN join == innerjoin right join == RIGHT OUTER JOIN Print raw SQL queries for debugging $connection = \ Drupal :: service( ' database ' ); $query = $connection -> select( ' node ' , ' node ' ); $query -> fields( ' node ' , [ ' nid ' ]) -> condition( ' node.type ' , ' page ' ) // Debug. dump( $query -> __toString()); Which Table is in Left and whilch is in Right Lets suppose there are two tables, emp and deptt SELECT emp.name,emp.no,d_name FROM emp left outer join deptt on (emp.dept_no = dept.dept_no) it left Join , and in left side table is emp and right side table is deptt. When we perform the left join it return the emp table. Type of Joins : 1 - Inner join (Natural join)(join) 1.1 - Natural join 1.2 - Conditional join or theta join 1.3 - Equi join 2 - Outer join: ...
Trying to Learn new things on drupal.