Create a query using SQL based on Tbltransactions and tblProducts that calculate
ID: 3838448 • Letter: C
Question
Create a query using SQL based on Tbltransactions and tblProducts that calculates total sales volume for each ProductType. Use the INNER JOIN clause to connect the two tables. Use the AS clause to rename the calculated field that totals the Quantity filed as HighSalesVolume. Group the results by ProductType. Use the HAVING clause to ensure that only products with a toal quarter 1 sales volume of at least 200 are returned. Use the ORDER BY clause to sort the results in descending order by the calculated field. (Using Microsoft Access)
Explanation / Answer
Select sum(sales) as HighSalesVolume from tblProducts inner join Tbltransactions on tblProducts.productype=Tbltransactions.productype group by tblProducts.productype order by tblProducts.productype desc
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.