Choosing a JOIN for the situation in front of you
Pick a join type, paste both tables as they are, and you get the result row count, the actual joined rows and a block of SQL that expresses the same join. The result table is computed from your input on the spot rather than copied from a worked example, so you can edit rows and watch the difference immediately.
INNER keeps only matching rows, so neither side ever gets a NULL. LEFT keeps every left row and fills the right-hand columns with NULL where no partner exists, and RIGHT does the reverse. FULL OUTER keeps both sides, and CROSS builds every combination with no condition, making the row count the product of the two tables. Cells filled with NULL are marked in red in the table.
When a join value repeats, pairs multiply and the result grows beyond the input row count; the matching-pair count is reported separately so you can see why. A row whose join column is NULL pairs with nothing. As of October 2026 this page supports neither CSV values containing commas nor WHERE and GROUP BY clauses.
Frequently Asked Questions
In a LEFT JOIN the right-hand columns go NULL for unmatched left rows, and a RIGHT JOIN is the mirror image. FULL OUTER produces NULL on both sides, while INNER and CROSS produce none at all.
Because a repeated join value lets one row pair with several. In the default sample the right table carries the same department id twice, so that employee appears twice.
NULL is not considered equal even to another NULL, so such a row pairs with nothing. In a LEFT JOIN the row still survives, with the right-hand columns filled with NULL.