Question: SQL Question 3: 1) List the Mfr Id, the Product Id, Company and PRICE of all products brought by customers where customer number is one

SQL Question 3:

1) List the Mfr Id, the Product Id, Company and PRICE of all products brought by customers where customer number is one of (2112,2105,2119) and where the amount of the order < $5000.00. Order the results by ascending Company.

2) List all salesreps (id and names) and all orders (orderNumber) in which the salesrep is the companys (i.e. the customer) rep (Cust Rep), but didnt take the order. Order the result based on name in ascending order.

3) List all customers (Customer number, Company, and Credit Limit) and orders (Order Number, Amount) where the order is within $10000.00 of the Credit Limit (less than or equal to $10000). Sort the result by Customer number in descending order.

4) List all salesreps names and their managers names where the salesrep is at least as old as the manager.

5) List all salesreps (Name) and the City they work in where the sales of the salesrep < Quota and the sales for the office is < Target.

6) List the name, id, and hire date of the salesreps where at least one of the two conditions hold:

The salesrep sales should be greater than the quota

The salesrep has taken an order from Customer number 2117, 2111, or 2101.

Sort the result by the salesreps id.

7) List all orders (Order Number) over $25000 showing the company placing the order, the Customer Rep assign to the company, the Office id and the city where the Customer Rep works in, such that the Customer Reps manager is not the person who actually took the order.

8) List all customer reps (their name and their id) and their managers name in which the manager has taken an order for the customer Reps company or the manager is based in New York or Denver. Use appropriate column header

9) List all products (ProductId, and Description), customers (CustNum, Company) who have bought that product, and orders (Order Number, and Order Date) where the order < $1000. Sort the rows by the OrderDate.

10) List the name of the salesreps and the name of their managers only if the manager has taken care of some orders.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!