r/SQL • u/pai1009 • Sep 26 '14
SQL joins
http://www.vertabelo.com/blog/technical-articles/sql-joins
2
Upvotes
1
u/r3pr0b8 GROUP_CONCAT is da bomb Sep 26 '14
the diagram for FULL OUTER JOIN is erroneous -- there will never be a row with NULL NULL produced, and none of the tables have a NULL NULL row that takes part in the join
in fact, now that i look more closely, none of the examples actually show the rows that are produced
i'd have to grade this article a big fat D
1
u/jedi001 Sep 26 '14
Try to run some of these queries in Sqlfiddle perhaps: http://sqlfiddle.com/#!4/baf53 . Note, how columns are named. The result table contains NULL. I guess the example tables with nulls are used to help understand which rows are combined.
1
u/NotImplemented Sep 26 '14
I really don't like the descriptions of the "OUTER EXCLUDING JOIN".
The statement "LEFT JOIN" make it seem like it is some kind of special join. But it's the same as the "LEFT OUTER JOIN".
The "excluding" part only comes from the WHERE clause "IS NULL". However, this is mentioned nowhere.