I have two tables of customer information, Tables A and B. They share no columns besides the ones found in the query, and all customers from Table B can be found in the much larger Table A.
Whenever I try to combine the customer data I end up eliminating the customers in A but not in B, or I end up getting way too many rows by getting repeat entries. How do I join the tables so I retain all of Table A and only add Table B columns to the customers found in both? Here is my best attempt:
select a.*, b.*
from table a
join table b
on a.id = b.id
where a.name = b.name ##OR?
**That will give me everything I need EXCEPT it only gives me the customers in both tables. I think I need to include some type of or statement to allow for cases where the customer is found in Table A but not Table B but I'm not sure how to set that up.