Bird
0
0

Why do we use an OUTER JOIN instead of an INNER JOIN in SQL?

easy📝 Conceptual Q1 of 15
SQL - LEFT and RIGHT JOIN
Why do we use an OUTER JOIN instead of an INNER JOIN in SQL?
ATo delete rows that do not match between tables
BTo include rows that do not have matching values in both tables
CTo combine only rows with matching values from both tables
DTo speed up query execution by skipping unmatched rows
Step-by-Step Solution
Solution:
  1. Step 1: Understand INNER JOIN behavior

    INNER JOIN returns only rows with matching values in both tables, excluding unmatched rows.
  2. Step 2: Understand OUTER JOIN purpose

    OUTER JOIN includes all rows from one or both tables, even if there is no match, filling missing values with NULL.
  3. Final Answer:

    To include rows that do not have matching values in both tables -> Option B
  4. Quick Check:

    OUTER JOIN purpose = include unmatched rows [OK]
Quick Trick: Outer joins keep unmatched rows with NULLs [OK]
Common Mistakes:
MISTAKES
  • Thinking outer joins only return matched rows
  • Confusing outer join with filtering unmatched rows
  • Assuming outer joins delete unmatched rows

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More SQL Quizzes