INNER JOIN
Suppose, we have two tables: Customers (with CustomerID, Name, and CountryID columns) and Orders (with OrderID, CustomerID, and OrderDate columns).
Using the INNER JOIN we can create a result table containing the CustomerID, Name, OrderID, and OrderDate columns. In such a simple way, we will be able to see
who and when created an order. The tables will be matched based on the common CustomerID column, and the unmatched row won't get into the result dataset.
LEFT OUTER JOIN
Suppose we have the Products and Orders tables that have a common ProductId column. With the help of the LEFT OUTER JOIN we can combine the two tables in a result table
that will contain all the rows from the Products table and in case, no records match from the Orders table, the NULL values will be shown in the OrderID column. In such a simple
way, we will be able to see which products have not been ordered yet.
RIGHT OUTER JOIN
The RIGHT OUTER JOIN works similarly to the LEFT OUTER JOIN but in the opposite direction. Let's consider the Vendors and Orders tables.
Using the RIGHT OUTER JOIN we can retrieve records for all Vendors showing their Purchase Orders. In case a vendor hasn't placed any orders yet, NULLs will be displayed
in the PurchaseOrderId column.