Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a query to display the SKU (stock keeping unit), description, type, base, category, and price for all products that have a PROD_BASE of Water

image text in transcribed

  1. Write a query to display the SKU (stock keeping unit), description, type, base, category, and price for all products that have a PROD_BASE of Water and a PROD_CATEGORY of Sealer
  2. Write a query to display a brand name and the number of products of that brand that are in the database. Sort the output by the brand name
  3. Write a query to display the number of products in each category that has a water base.
  4. Write a query to display the brand ID, brand name, and average price of products of each brand. Sort the output by brand name. Results are shown with the average price rounded to two decimal places
  5. Write a query to display the customer code, first name, last name, and sum of all invoice totals for customers with cumulative invoice totals greater than $1,500. Sort the output by the sum of invoice totals in descending order. (Hint: you need to use HAVING with SUM in the condition statement

Thanks for the assistance!

LGCUSTOMER PK Cust Code LGBRAND PK Brand ID Cust_Fname Cust Lnamo Cust_Street Cust City Cust_State Cust_ZIP Cust_Balance Brand Name Brand Type inclados inace places LGPRODUCT PK Prod SKU LGINVOICE PK Iny Num appears on 14 # contains LGLINE PK,FK1 InvNum PK Line Num FK2 Prod SKU Line Qty Lino Prico FK1 Cust Code Inv_Data Inv_Total FK2 Employoo_ID Prod_Descript Prod_Type Prod Base Prod_Category Prod_Price Prod QOH Prod Min FK Brand_ID completes provided by LGEMPLOYEE PK Emp Num LGSALARY_HISTORY PK,FK1 Emp Num PK Sal From LGSUPPLIES PK,FK1 Vend ID PK,FK2 Prod SKU has Emp_Frame Emp_Lname Emp_Email Emp_Phone Emp Hiredate Emp_Title Emp Comm FK1 Dept Num Sal_End Sal_Amount proudes employs manages LGDEPARTMENT PK Dept_Num LGVENDOR PK Vend.ID Vend_Namo Vend Street Vend_City Vend State Vend_ZIP Dept_Name Dept_Mail_Box Dopt_Phono FK1 Emp_Num 7

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions

Question

Explain the nature of qualitative data in detail?

Answered: 1 week ago

Question

9. System creates a large, diverse talent pool.

Answered: 1 week ago