join用于將多個表的數據組合顯示。
The result of a left outer join (or simply left join) for tables A and B always contains all rows of the "left" table (A), even if the join-condition does not find any matching row in the "right" table (B). This means that if the ON clause matches 0 (zero) rows in B (for a given row in A), the join will still return a row in the result (for that row)—but with NULL in each column from B.
left_join是以左表為主表,join的表是為了配合左表,查不到的部分在左表中就顯示為null。
215px-SQL_Join_-_01_A_Left_Join_B.svg.png
參考:
https://coolshell.cn/articles/3463.html
https://en.wikipedia.org/wiki/Join_(SQL)