SQL Join

 cross join – match combinations

union – stack, unique

union all – stack, include duplicates

intersect – result in the intersection

except – result in the exception

semi join – select rows from 1st table that are ALSO present in 2nd table
where (field) in (table)

anti join – select rows from 1st table that are NOT present in 2nd table
where (field) not in (table)

2018-11-06 13_41_15-Semi-joins and Anti-joins _ Sql.png

 

Subclause can be used instead of group by!

 

Comments

Popular posts from this blog

Jonas - Javascript

R - Supervised Learning

Consulting Interview