Here comes the most important table:
Product! It contains all products that are sold throughout the store, along with information on how to locate them.
Quick reminder: pay attention to the columns that have the same names as those from another table. For instance:
Car.Name AS CarName,
Owner.Name AS OwnerName
ON Car.OwnerId = Owner.Id
Name is available in both the
Owner tables. In the query, we prefix each column's name with the name of the table it comes from (
Owner.Name). This way, the database knows which column we want to select.
Then, we use aliases to make the resulting query more readable.