Please enable JavaScript.
Coggle requires JavaScript to display documents.
Ch. 9 Data Integrations (Joins (Inner join (row in left table combined…
Ch. 9 Data Integrations
Joins
Combine 2 data sets with id shared value(ex: customer id)
Add more info about customer - grow tables with more columns
Inner join
row in left table combined horizontally with row in right table w/ same id info
Contain repeated info (customerid)
CustId, Name, CustId, Product -> 1, Kai, 1 pants
1, Kai, 1, bouncing castle
Outer join
Left outer join
adds rows in left able that do not have corresponding rows in right table
Contain NULL
CustId, Name, CustId, Product -> 1, Kai, 1 pants 1, Kai, 1 bouncing castle 2, Dan, NULL, NULL
NULL = Dan bought nothing yet
Right outer join
adds rows from right table that do not have corresponding rows in left table
CustId, Name, CustId, Product -> 1, Kai, 1 pants 1, Kai, 1, bouncing castle
NULL, NULL, 3, Sunglasses
NULL = unregistered customer w/ abandoned cart
Full outer join
same result as inner join + left outer join + right outer join
CustId, Name, CustId, Product -> 1, Kai, 1, pants 1, Kai, 1 bouncing castle 2, Dan, NULL, NULL NULL, NULL, 3, sunglasses
All info from both tables combined
Union
Line up columns to add more rows
Add more customers to a dataset
Use if dataset has unique cases sharing similar columns
ex: unionize lists of parishioners at 20 different churches, synagogues, and mosques
Must carefully examine data for duplicate cases
Differences
Joins = add data horiztonally
Unions = add data vertically