Question
SQL Assignment 1 Copy your queries and paste it under each question. Upload the file to the Canvas submission folder. Using Teradata ViewPointDatabase: db_pvfc11_big1. 1.List
SQL Assignment 1 Copy your queries and paste it under each question. Upload the file to the Canvas submission folder. Using Teradata ViewPointDatabase: db_pvfc11_big1. 1.List all raw materials that are made of cherry and that have dimensions (thickness and width) of 12 by 12. 2. Retrieve the product line ID and the average standard price for all products in each product line. 3. Retrieve the product line ID and the average standard price for products whose standard price greater than $200 in each product line. Include in the answer set only those product lines that have an average standard price of at least $500. 4. For each order, display the order ID, the number of separate products included in the order, and the total number of product units (for all products) ordered. 5. For each customer, list the CustomerID and total number of orders placed. 6. Display the product ID and the number of orders placed for each product. Show the results in decreasing order by the number of times the product has been ordered and label this result column NumOrders. 7. For each customer, list the customer ID and the total number of orders placed in and after 2010. 8. For employees who live in TN or FL, list the age at which they were hired. (Hint: age hired can be computed using EmployeeDateHired - EmployeeBirthDate) 9. Display the territory ID and the number of sales persons in the territory for all territories that have more than one sales person. Label the number of salespersons as NumSalesPersons. 10. List MaterialName, Material, and Width for raw materials that are not cherry or oak and whose width is greater than 10 inches.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started