TomoLink
CompaniesPhonePeSystem DesignHow do SQL Joins Work?
System Design
Mediumtechnical-interviews

How do SQL Joins Work?

30 minsSQLDatabase
30 mins
1 sections
SQL, Database

Overview

The diagram above shows how 4 types of SQL joins work in detail.

INNER JOIN

Returns matching rows in both tables.

LEFT JOIN

Returns all records from the left table, and the matching records from the right table.

RIGHT JOIN

Returns all records from the right table, and the matching records from the left table.

FULL OUTER JOIN

Returns all records where there is a match in either left or right table.

How do SQL Joins Work? [Medium] | PhonePe System_design | TomoLink