Question

uu Payments check Number paymentate amount customer Number Offices officeCode city phone addressLine1 addressLine2 state coun
5. (20 points) List the product name, the customer name, the sales rep first name and last name, and the order number for all
0 0
Add a comment Improve this question Transcribed image text
Answer #1

5)

SELECT p.productName, c.customerName, e.firstName, e.lastName, o.orderNumber from Customers c, Employees e, Orders o, OrderDetails od, Products p where c.salesRepEmpoyeeNumber = e.employeeNumber and c.customerNumber = o.customerNumber and o.orderNumber = od.orderNumber and od.productCode = p.productCode order by e.lastName, e.firstName, c.customerName;

6)

select productCode, productName FROM Products where productCode not in (select productCode from OrderDetails od JOIN Orders o on od.orderNumber = o.orderNumber where  o.orderDate >= "2005-05-10") order by productName;

Add a comment
Know the answer?
Add Answer to:
uu Payments check Number paymentate amount customer Number Offices officeCode city phone addressLine1 addressLine2 state country...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Using this relations scheme: write these queried in relational algebra 2.List productCode, productName, and productVendor for...

    Using this relations scheme: write these queried in relational algebra 2.List productCode, productName, and productVendor for each product that has never been ordered in June. Remember that we have the month function that returns the number of the month component of a data, and January is month number 1. 3.List the Customers that did not Order any products in 2015. 4.List all CustomerNames who have never had an order go to the ‘Shipped’ status. 1.. products FK product Code product...

  • Customer Product Manufacturer ManufacturerID ManufacturerName Addressi Address2 City State PostalCode Phone Fax Contact URL Sale Saleltem...

    Customer Product Manufacturer ManufacturerID ManufacturerName Addressi Address2 City State PostalCode Phone Fax Contact URL Sale Saleltem CustomerID FirstName LastName StreetAddress City State PostalCode Country Phone SalelD SaleDate CustomerID Tax Shipping SaleID ProductiD ItemSize Quantity SalePrice ProductID ProductName ManufacturerID Composition ListPrice Gender Category Color Description Employee EmployeelD o FirstName LastName Address City State ZIP Phone ManagerlD SSN EmailAddress HireDate SalaryEmployee EmployeelD o Salary WageEmployee EmployeelD o Wage MaxHours What are the dollar amounts of each Sale (add all SaleItem amounts) for...

  • The business process we are interested in is sales(i.e., selling products to customers). Develop a logical...

    The business process we are interested in is sales(i.e., selling products to customers). Develop a logical star- or snowflake-schema dimensional model. orders customers + PK FK orderdetails PK/EK OrderID PK/FK Products UnitPrice Quantity Discount PK OrderID Customer D FK Employeeld Order Date RequiredDate Shipped Date FK ShipVia Freight ShipName ShipAddress ShipCity ShipRegion ShipPostalCode Ship Country CustomerID CompanyName ContactName Contact Title Address City Region PostalCode Country Phone shipppers PK Shipperid CompanyName Phone Fax products PK ProductID + employees PK Employeeld LastName...

  • Create the following SQL Server queries that access the Northwind database Same as problem 3 but,...

    Create the following SQL Server queries that access the Northwind database Same as problem 3 but, limit the list to all customers who placed 3 or more orders. The product id, product name, last date that the product was ordered for all items in the Grains/Cereals category. (Hint: Use MAX) The product ID, product name, and number of distinct customers who ordered that product in 1996 Thank you. Categories Customers Employees Order Details Orders Products Shippers 9 CategoryID CategoryName Description...

  • can someone solve these quick please and thank you! sql chapter 4 Query #1: List the...

    can someone solve these quick please and thank you! sql chapter 4 Query #1: List the company name, contact name, contact title and the phone number for customers who HAVE NOT put in an order. Use an outer join. Query #2: Create a listing displaying the employee first name, last name and the full name (First name space Last Name) of the person they report to (Supervisor). This is a self-join. If an employee does not report to anyone then...

  • An online company sells hundreds of office supply products on its e-Commerce store. It has asked...

    An online company sells hundreds of office supply products on its e-Commerce store. It has asked you to design and implement a sales order processing system which will be used by users in our Operations department to process sales orders. Here is an overview of the sales order process. Customers make purchases by placing orders. Each customer has a customer number and profile (such as name, shipping address). To simplify the matter, each time an order is placed, only one...

  • Write a query that lists the top 3 suppliers ordered by their contact name in descending...

    Write a query that lists the top 3 suppliers ordered by their contact name in descending order Write a query that list all the countries that start with the litter M. Make sure you don’t have any duplicates. List all product Name and unit price. Order the result by the unit price un descending order Customer > Customer int <p FirstName nvarchar(40) LastName nvarchar(40) City nvarchar(40) Country nvarchar(40) Phone nvarchar(20) 8 IndexCustomerName Supplier Supplier int spk Order Order int <pk>...

  • The Northwind database created by Microsoft contains the sales data for a fictitious company called Northwind...

    The Northwind database created by Microsoft contains the sales data for a fictitious company called Northwind Traders, which imports and exports specialty foods from around the world. Here is the schema of the database: Products (ProductID, ProductName, SupplierID, CategoryID, QuantityPerUnit, UnitPrice, UnitsInStock, UnitsOnOrder, ReorderLevel, Discontinued); Suppliers (SupplierID, CompanyName, ContactName , ContactTitle, Address, City, Region, PostalCode, Country, Phone, Fax, HomePage); Categories (CategoryID, CategoryName, Description, Picture); Orders (OrderID, CustomerID, EmployeeID, OrderDate, RequiredDate, ShippedDate, ShipVia,  Freight, ShipName,ShipAddress, ShipCity, ShipRegion, ShipPostalCode, ShipCountry); Order_details (ID, OrderID,...

  • Questions are based on the Northwind database. a. A data dictionary (Excel file) that describes each...

    Questions are based on the Northwind database. a. A data dictionary (Excel file) that describes each of the tables. (Attached in question) b.    Write good, clean SQL that answers the following questions. c.     Separate your queries as I have done in the following example. End each query with a semicolon (;) and insert the word "go" between each query. Queries can span multiple lines if required. Select CustomerID from Customers; go Select Count(*) from Employees; go Select max(productID) from Products; 18. Produce...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT