How does inner, left, right, full join work?
When and what is a JOIN?
Querying data in your database from only one table can only get you so far, sometimes one table just doesn't contain all the data you need. Your current table product may be referencing a foreign key in another table called user by an user ID. If you want to see which product is purchased by who then just querying the product would not be enough.
That's where JOIN is needed it will pull in the data from both table in this case product and user in order to tell you who purchased a particular product.
Dataset
Let's take a look at the current dataset that we will be working with to do the test.