# What is a LEFT JOIN in SQL?

> A LEFT JOIN keeps every row from the first table even with no match in the second. Why it matters for "who has not ordered" questions, with an example.

Source: https://learn.ynteractive.com/content/glossary/left-join · Updated 2026-10-24 · Free from Stepthrough (https://learn.ynteractive.com)

[Data, Sheets and Gmail](https://learn.ynteractive.com/content/glossary#topic-data-sheets-and-gmail) · [AI glossary](https://learn.ynteractive.com/content/glossary)

Quick answer

A LEFT JOIN combines two tables and keeps every row from the first (left) table, even when the second table has no matching row; the missing values come back as null. A plain JOIN (inner join) keeps only rows that match on both sides.

Last updated October 24, 2026

[Take the free module →](https://learn.ynteractive.com/courses/sql-for-business-reports/3)Module 3 of the free [SQL for Business Reports Jump Start](https://learn.ynteractive.com/courses/sql-for-business-reports) course, about 15 minutes. No account needed.

Updated October 24, 2026 · By [Robert Breen](https://learn.ynteractive.com/content/about)

## Why it matters for a small business

Business data is split across tables: customers in one, orders in another, invoices in a third. A JOIN puts them side by side using a shared column, such as the customer name or id.

The difference matters most for "who has not ..." questions. Customers who never ordered, invoices with no payment, leads with no reply: a plain JOIN silently drops them, which are exactly the rows you are looking for. A LEFT JOIN keeps them, with null in the empty columns.

A LEFT JOIN is also the safe default when you add details from a second table to a list you already trust. Joining a customer list to the account managers table with a plain JOIN quietly loses any customer who has no manager yet; with a LEFT JOIN every customer stays on the list and the gaps show up as null, ready to be fixed.

## In a real lesson: SQL: Find Customers Who Have Gone Quiet with a LEFT JOIN

In the free [SQL quiet customers lesson](https://learn.ynteractive.com/content/sql-quiet-customers), Lakeside Office Supply (made up) joins five customers to their orders to find each one's latest order date. With a plain JOIN only four rows come back: Elm Street Law, which never ordered, is missing.

Changing JOIN to LEFT JOIN brings Elm Street Law back with a null last order, and HAVING MAX(o.order_date) < '2026-09-01' OR MAX(o.order_date) IS NULL leaves the Monday call list: Elm Street Law, Harbor Accounting and Maple Dental.

[Try this lesson free](https://learn.ynteractive.com/modules/sql-quiet-customers) or [read the step-by-step guide](https://learn.ynteractive.com/content/sql-quiet-customers).

## Common confusions

### JOIN vs LEFT JOIN

JOIN (inner join) keeps only matching rows. LEFT JOIN keeps every row of the left table and fills the rest with null.

### LEFT JOIN vs RIGHT JOIN

A RIGHT JOIN keeps every row of the second table instead. Most people write every join as a LEFT JOIN and put the table they want in full first.

## Tips

- Put the table you want to keep in full right after FROM.
- Test for missing matches with IS NULL, never with = NULL.

## Related terms

[SQL](https://learn.ynteractive.com/content/glossary/sql) · [GROUP BY (SQL)](https://learn.ynteractive.com/content/glossary/group-by)

## More Data, Sheets and Gmail terms

Merge field · Natural language query · [pandas (Python)](https://learn.ynteractive.com/content/glossary/pandas) · [Parsing rules](https://learn.ynteractive.com/content/glossary/parsing-rules)

## Where you use it: free lessons

- [SQL: Find Customers Who Have Gone Quiet with a LEFT JOIN](https://learn.ynteractive.com/content/sql-quiet-customers) (DB Fiddle, 15 min)

## Frequently asked questions

**When should I use LEFT JOIN instead of JOIN?**

Whenever rows without a match matter, for example customers with no orders or invoices with no payment. A plain JOIN would drop them.

**Why do I see null after a LEFT JOIN?**

Null means the left-hand row had no matching row in the other table, such as a customer with no orders.

**Does LEFT JOIN work the same in MySQL and PostgreSQL?**

Yes. LEFT JOIN is standard SQL and works the same way in MySQL, PostgreSQL, SQL Server and SQLite.

[All AI glossary terms, A to Z](https://learn.ynteractive.com/content/glossary) · [Free prompt templates](https://learn.ynteractive.com/content/prompts)
