1. List OrderIDs and the associated Employee Names for orders that shipped after the required date. (Hint: Employees to Orders is a one-to-many relationship. So JOIN the two table Employees and Orders and have the WHERE clause filter orders with ShippedDa
1. List OrderIDs and the associated Employee Names for orders that shipped after the required date.
(Hint: Employees to Orders is a one-to-many relationship. So JOIN the two table Employees and Orders and have the WHERE clause filter orders with ShippedDate > RequiredDate)
2. List Products (ProductID, ProductName) and their Suppliers (SupplierID, CompanyName)
(Hint: Suppliers and Products have one-to-many relationship, so JOIN the two table Suppliers and Products)
3. List all Customers (CustomerID, CompanyName) and their Orders (OrderID, OrderedDate)
(Hint: Customers and Orders have one-to-many relationship, and since all Customers is mentioned which means you need to do a LEFT OUTER JOIN)
4. List Customers (CustomerID, CompanyName) and Orders (OrderID, OrderedDate) including the ones they have not placed
(Hint: Customers and Orders have one-to-many relatinship, and since all Orders is mentioned which means you need to do a RIGHT OUTER JOIN)
5. List all Categories (CategoryID, CategoryName) and all Products (ProductID, ProductName)
(Hint: Categories and Products have one-to-many relationship, and since all Categories and all Products is mentioned do a FULL OUTER JOIN)
9 years ago
Purchase the answer to view it

- queries_3.sql_.zip