Bird
0
0

What happens to rows in the left table when there is no matching row in the right table during a LEFT JOIN?

easy📝 Conceptual Q1 of 15
SQL - LEFT and RIGHT JOIN
What happens to rows in the left table when there is no matching row in the right table during a LEFT JOIN?
AThey are duplicated
BThey are excluded from the result
CThey appear with NULL values for the right table columns
DThey cause an error
Step-by-Step Solution
Solution:
  1. Step 1: Understand LEFT JOIN behavior

    A LEFT JOIN returns all rows from the left table regardless of matches in the right table.
  2. Step 2: Check unmatched rows handling

    If no matching row exists in the right table, the columns from the right table are filled with NULL.
  3. Final Answer:

    They appear with NULL values for the right table columns -> Option C
  4. Quick Check:

    LEFT JOIN unmatched rows = NULL columns [OK]
Quick Trick: LEFT JOIN keeps all left rows, fills right with NULL if no match [OK]
Common Mistakes:
MISTAKES
  • Thinking unmatched rows are excluded
  • Assuming unmatched rows cause errors
  • Believing unmatched rows duplicate

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More SQL Quizzes