Question

Your task is to create a “report” that shows the following: a. Customer names with an...

Your task is to create a “report” that shows the following:

a. Customer names with an alias

b. Product names with an alias

c. Total price calculated as (UnitPrice*(1-Discount)*Quantity) with the alias “Total Price”

d. Round “Total Price” to zero decimal places e. Sort by Customer and then by product

0 0
Add a comment Improve this question Transcribed image text
Answer #1

The following is the query for the given question:

select CustomerName as customer , ProductName as product , ROUND((UnitPrice*(1-Discount)*Quantity),0 )
as TotalPrice from report order by customer,product;

The above query represents alias for CustomerName, ProductName, the calculation for TotalPrice, and also “Total Price” is rounded to zero decimal places,and Sorted by Customer and then by product.

Add a comment
Know the answer?
Add Answer to:
Your task is to create a “report” that shows the following: a. Customer names with an...
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
  • use workbench please Task 1: Create a database and name it practical2DB. (2 marks) Task 2:...

    use workbench please Task 1: Create a database and name it practical2DB. (2 marks) Task 2: Create all the four tables according to the relational scheme in Figure 1. (8 marks) Task 3: Insert 5 records to into each table. (5 marks) Task 4: Write a query to list alphabetically ordered names, addresses, and IDs of all the customers whose postcode is in (40150, 40400, 47500). (10 marks) Task 5: Delete 1 record from Products table using their primary keys....

  • 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...

  • Table (a) shows the cost data for Farmer Mill, a barley farmer. Round your answers to...

    Table (a) shows the cost data for Farmer Mill, a barley farmer. Round your answers to 2 decimal places. a) Complete table (a). Total Cost ($) Variable Cost ($) Recage Total Cost ($) Marginal Cost ($) Quartity Recage Variable Cost ($) 1 14 18 10 16 46 60 b) What are the values of the break-even and shutdown prices? Round your answer to 2 decimal places. Break-even price: $ 8 Shutdown price: $ c) Given the prices shown in column...

  • 28. A weekly factory production report shows the following data: Product units produced Standard Direct Labor...

    28. A weekly factory production report shows the following data: Product units produced Standard Direct Labor (DL) time for 18,000 units 20,000 hours Standard DL rate per hour Actual DL time used in production: 20,800 hours Actual DL rate per hour Standard Direct Materials (DM) cost per unit Standard Factory Overhead (FO) rate: 40% of DL cost 18.00 Instructions (a, b, c): Calculate the following variances: please indicate (unfavorable) with your answer: 521.00 520.00 a) DL rate variance averable) er...

  • 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...

  • CREATE TABLE customer (    id INTEGER PRIMARY KEY,    customer_name TEXT,    contact_number TEXT );...

    CREATE TABLE customer (    id INTEGER PRIMARY KEY,    customer_name TEXT,    contact_number TEXT ); CREATE TABLE supplier (    id INTEGER PRIMARY KEY,    supplier_name TEXT UNIQUE,    contact_number TEXT ); CREATE TABLE product (    id INTEGER PRIMARY KEY,    supplier_id INTEGER REFERENCES supplier(id),    product_name TEXT,    product_price INTEGER,    UNIQUE(supplier_id, product_name) ); CREATE TABLE purchase (    id INTEGER PRIMARY KEY,    customer_id INTEGER REFERENCES customer(id),    purchase_date REAL,    store_id INTEGER REFERENCES store(id) );...

  • Rooney Manufacturing Company produces a single product. The following data apply to the standard cost of...

    Rooney Manufacturing Company produces a single product. The following data apply to the standard cost of materials and labor associated with making the product: Materials quantity per unit Materials price Labor quantity per unit Labor price 1 pound $ 6.20 per pound 2 hours $10.20 per hour $10.22 hours During the year, the company made 2,040 units of product. At the end of the year, the following variances had been calculated. Materials usage variance Materials price variance Labor usage variance...

  • Rooney Manufacturing Company produces a single product. The following data apply to the standard cost of...

    Rooney Manufacturing Company produces a single product. The following data apply to the standard cost of materials and labor associated with making the product: Materials quantity per unit Materials price Labor quantity per unit Labor price 1 pound $ 6.20 per pound 2 hours $10.20 per hour During the year, the company made 2,040 units of product. At the end of the year, the following variances had been calculated. Materials usage variance Materials price variance Labor usage variance Labor price...

  • Vernon Manufacturing Company produces a single product. The following data apply to the standard cost of...

    Vernon Manufacturing Company produces a single product. The following data apply to the standard cost of materials and labor associated with making the product: Materials quantity per unit Materials price Labor quantity per unit Labor price 1 pound $ 6.60 per pound 2 hours $10.60 per hour During the year, the company made 2,120 units of product. At the end of the year, the following variances had been calculated. Materials usage variance Materials price variance Labor usage variance Labor price...

  • The following table shows some data for three zero-coupon bonds. The face value of each bond...

    The following table shows some data for three zero-coupon bonds. The face value of each bond is $1,000 Bond Price Maturity (Years) Yield to Maturity A $ 380 20 — B 380 — 10 % C — 18 9 a. What is the yield to maturity of bond A? (Do not round intermediate calculations. Enter your answer as a percent rounded to 3 decimal places. Assume annual compounding.) b. What is the maturity of B? (Do not round intermediate calculations....

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