Lab 10 - Lab 10 Answer Key QBE View followed by QBE-Built...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
Lab 10 Answer Key QBE View followed by QBE-Built SQL View 1. List the category name and the product name of all products in the Dairy Products category. SELECT Categories.CategoryName, Products.ProductName FROM Categories INNER JOIN Products ON Categories.CategoryID = Products.CategoryID WHERE (((Categories.CategoryName)="Dairy Products")); 2. Report the company name, contact name, and phone number of the customers for all orders that have not been shipped. SELECT Customers.CompanyName, Customers.ContactName, Customers.Phone, Orders.ShippedDate FROM Customers INNER JOIN Orders ON Customers.CustomerID = Orders.CustomerID WHERE (((Orders.ShippedDate) Is Null));
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
3. For each order shipped into Germany, list the order ID, the company name of the customer, the order date, and the company name of the shipper. Sort the results in alphabetical order by company name and within company name in chronological order by order date. SELECT Customers.CompanyName, Orders.OrderID, Orders.OrderDate, Shippers.CompanyName FROM Shippers INNER JOIN (Customers INNER JOIN Orders ON Customers.CustomerID = Orders.CustomerID) ON Shippers.ShipperID = Orders.ShipVia WHERE (((Orders.ShipCountry)="Germany")) ORDER BY Customers.CompanyName, Orders.OrderDate; 4. Report the company name of each shipper and the total amount of freight they have charged. SELECT Shippers.CompanyName, Sum(Orders.Freight) AS
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 01/30/2012 for the course CNIT 180 taught by Professor Victorbarlow during the Spring '12 term at Purdue University-West Lafayette.

Page1 / 6

Lab 10 - Lab 10 Answer Key QBE View followed by QBE-Built...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online