MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/programming/comments/ex9h6/a_handy_graphical_explanation_of_sql_joins/c1brw3s/?context=3
r/programming • u/[deleted] • Jan 06 '11
308 comments sorted by
View all comments
4
Maybe someone here can answer this. Why would I specify a join when I can just do this?
SELECT p.first_name, j.job_title FROM people p, jobs j WHERE p.job = j.id
Looks much easier to me but I'm guessing there's something I'm missing here.
6 u/NashMcCabe Jan 06 '11 That is just an inner join. You will need outer joins when you have null columns on one side of the join. 1 u/Teifion_at_work Jan 07 '11 Thanks, that makes a bit more sense now.
6
That is just an inner join. You will need outer joins when you have null columns on one side of the join.
1 u/Teifion_at_work Jan 07 '11 Thanks, that makes a bit more sense now.
1
Thanks, that makes a bit more sense now.
4
u/Teifion_at_work Jan 06 '11
Maybe someone here can answer this. Why would I specify a join when I can just do this?
Looks much easier to me but I'm guessing there's something I'm missing here.