Question: For every invoice, display the invoice number, invoice date and the total dollar amount for all products purchased in the invoice, ordered by invoice number
For every invoice, display the invoice number, invoice date and the total dollar amount for all products purchased in the invoice, ordered by invoice number in descending order. Here you will use an aggregate SUMxy function in your SELECT clause to calculate the total dollar amount a calculated field name it with the alias TOTAL
CUSTOMER TABLE
CUSCODE CUSLNAME CUSFNAME CUSINITIAL CUSAREACODE CUSPHONE CUSBALANCE
Ramas Alfred A
Dunne Leona K
Smith Kathy W
Olowski Paul F
Orlando Myron
O'Brian Amy B
Brown James G
Williams George
Farriss Anne G
Smith Olivette K
INVOICE
INVNUMBER CUSCODE INVDATE
JAN
JAN
JAN
JAN
JAN
JAN
JAN
JAN
LINE
INVNUMBER LINENUMBER PCODE LINEUNITS LINEPRICE
QP
HB
T
QPD
QQ
QP
T
HB
PVCDRT
SM
QTY
HB
WREQ
QP
T
PVCDRT
WRTT
HB
PRODUCT
PCODE PDESCRIPT PINDATE PQOH PMIN PPRICE PDISCOUNT VCODE
QER Power painter, psi., nozzle NOV
QP in pwr saw blade DEC
QLin pwr saw blade NOV
QQ Hrd cloth, inxJAN
QW Hrd cloth, inxJAN
QTY BD jigsaw, in blade DEC
QWE BD jigsaw, in blade DEC
QPD BD cordless drill, inJAN
HB Claw hammer JAN
AA Sledge hammer, lbJAN
T Rattail file, in fine DEC
WREQ Hicut chain saw, inFEB
PVCDRT PVC pipe, inft FEB
SMin metal screw, MAR
SWin wd screw, FEB
WRTT Steel, xx mesh JAN
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
