Complete the code to join two tables on the 'CustomerID' field.
FROM Customers [1] Orders ON Customers.CustomerID = Orders.CustomerIDThe INNER JOIN returns only matching records from both tables based on the 'CustomerID'.
Complete the code to perform a left join between 'Sales' and 'Products' on 'ProductID'.
SELECT * FROM Sales [1] Products ON Sales.ProductID = Products.ProductIDThe LEFT JOIN returns all records from the left table ('Sales') and matching records from the right table ('Products').
Fix the error in the join syntax to correctly join 'Employees' and 'Departments' on 'DeptID'.
SELECT * FROM Employees [1] Departments ON Employees.DeptID = Departments.DeptIDThe correct syntax requires INNER JOIN with an ON clause, not a WHERE clause for joining tables.
Fill both blanks to join 'Orders' and 'Customers' showing all orders and matching customers.
SELECT Orders.OrderID, Customers.Name FROM Orders [1] Customers [2] Orders.CustomerID = Customers.CustomerID
LEFT JOIN keeps all orders and matches customers. The ON clause specifies the join condition.
Fill all three blanks to join 'Products', 'Categories', and 'Suppliers' tables correctly.
SELECT Products.ProductName, Categories.CategoryName, Suppliers.SupplierName FROM Products [1] Categories [2] Products.CategoryID = Categories.CategoryID [3] Suppliers ON Products.SupplierID = Suppliers.SupplierID
Use INNER JOIN twice to join three tables. The ON clauses specify join conditions for each join.