Blog · Guide
LEFT JOIN vs INNER JOIN: Which Rows Survive?
INNER keeps matches only. LEFT keeps every row from the left table. A clear picture of what you gain and lose.
INNER = intersection
Only rows that match on the join key. Orders without a matching customer (data bugs) disappear from an INNER JOIN result.
LEFT = keep the left table
Every left-table row stays. If the right side has no match, right-hand columns are NULL. Use LEFT when “don’t lose left rows” matters more than “only complete pairs.”
How to choose
- Report of paid orders with customer names → usually INNER
- All customers, including those with zero orders → LEFT from customers to orders
Try it yourself
The fastest way to lock this in is a short drill on the same Northstar Market tables.