Erd
2010-07-04 17:07:30 UTC
The sample database has the following tables:
Department (DeptNo, DeptName, Office, Phone)
Employee (EmpNo, FirstName, LastName, JobTitle, HireDate, Salary, MgrNo, Deptno)
Customer (CustNo, CompanyName, Street, City, State, Zip, Phone, CreditLimit, AcctRepNo)
CustomerOrder (OrderNo, OrderDate, ShipDate, CustNo)
OrderLine (OrderNo, ProductNo, Quantity, ActualPrice)
Product (ProductNo, Description, QtyOnHand, MinStockLevel)
Price (ProductNo, StartDate, EndDate, StdPrice, MinPrice)
5. List the product number, product description, and order date for each time a tennis-related product was ordered by a customer in the state of Florida in 2006. (Assume that tennis-related products all have the word Tennis somewhere in their product description.) Order the list by product number, with a secondary sort by order date, from oldest order to newest order. Use the default column headings.
6. For all customers, list the company name and the total number of orders placed by the customer. Include all customers, even those who have never placed an order. Order the customers in the list by the number of orders placed, from most to fewest. For any customers with the same number of orders, arrange them within the list alphabetically by company name. Use Customer Name and Order Count as the column headings.
7. For all orders with a total price either over $7,000 or under $1,000, list the company name of the customer placing the order, the last name of the salesperson handling the customer’s account, the order number, and the total price for the order. Sort the orders from highest total price to lowest total price. For column headings use: Customer, Salesperson, Order, and Order Total.
8. For all customers that have never placed an order, list the customer’s company name, telephone number, account representative last name, and the last name of the manager of the account repre-sentative. Order the list by company name. For column headings, use: Company, Telephone, Salesperson, and Manager.