Skip to main content
PreparationZone Logo
PreparationZone
Back to Fundamentals

Fundamentals · Medium · Free

Explain INNER JOIN with a two-table example.

FresherFundamentalsDatabase Fundamentals
Model answer

INNER JOIN

sql
SELECT o.id, c.name
FROM orders o
INNER JOIN customers c ON c.id = o.customer_id
WHERE o.status = 'PAID';

Returns rows with matching keys in both tables.

Draw two circles—intersection is INNER.