Explain INNER, LEFT, RIGHT and FULL OUTER joins with an example.
beginner 0–2 yrs
INNER JOIN returns only rows with a match in both tables. LEFT JOIN returns every row from the left table plus matches, with NULLs where none exist; RIGHT is the mirror. FULL OUTER returns all rows from both sides. LEFT JOIN with WHERE right.id IS NULL finds rows with no match, a common data check.
Full answer with examples