INNER JOIN

INNER JOIN combines the rows of two tables for which the join condition is true, and keeps only the matches: a row with no counterpart on the other side disappears. With a one-to-many relationship, the row on the "one" side is repeated for each match.

Example

SELECT c.nom, o.total
FROM clients c
INNER JOIN commandes o ON o.client_id = c.id;

Related concepts

The whole glossary