Sorry I posted the wrong question. 1. Write a query to count the number of custo
ID: 3690839 • Letter: S
Question
Sorry I posted the wrong question.
1. Write a query to count the number of customers with a customer balance over $500 2. Find the listing of customers who did not make purchases during the invoicing period. Your output must match the output shown in Figure P7.40 FIGURE P7.40 Customer Balances for Customers Who Did Not Make Purchases CUS_CODE CUS_BALANCE 10010 10013 10016 10017 10019 0.00 536.75 221.19 768.93 0.00 3. Create a query to find the customer balance characteristics for all customers, including the total of the outstanding balances. The results of this query are shown in Figure P7.39 FIGURE P7.39 Customer Balance Summary for All Customers Total BalancesMinimum Balanace Maximum Balance Average Balance 2089.28 0.00 768.93 208.93 4. Create a query to produce the summary of the value of products currently in inventory. Note that the value of each product is produced by the multiplication of the units currently in inventory and the unit price. Use the ORDER BY clause to match the order shown in Figure P7.42. FIGURE P7.42 Value of Products in Inventory P DESCRIPT P QOH P PRICE Subtotal Power painter, 15 psi., 3-nozzle 7.25-in. pwr. saw blade 9.00-in pwr. saw blade Hrd. cloth, 1/4-in.,2x50 Hrd. cloth, 1/2-in., 3x50 B&D; jigsaw, 12-in. blade B&D; jigsaw, 8-in. blade B&D; cordless drill, 1/2-in Claw hammer Sledge hammer, 12 Rat-tail file, 1/8-in. fine Hicut chain saw, 16 in PVC pipe, 3.5-in., 8-ft 1.25-in. metal screw, 25 2.5-in. wd. screw, 50 Steel matting, 4x8x1/6 5" mesh List the balance characteristics of the customers who have made purchases during the current invoice 8 109.99 14.99 17.49 39.95 43.99 8 109.92 99.87 38.95 9.95 14.40 879.92 479.68 32 314 15 23 599.25 879.36 599 12 23 467.40 228.85 115.20 214.57 2826.89 1103.56 1202.28 2002.65 2159.10 43 188 172 237 6.99 8.45 8 119.95 5. cycle-that is, for the customers who appear in the INVOICE table. The results of this query are shown in Figure P7.37. FIGURE P7.37 Balances for Customers who Made Purchases cuS CODE CUS BALANCE 10011 10012 10014 10015 10018 0.00 345.86 0.00 0.00 216.55Explanation / Answer
first thing is that you have not given the database here, so these queries are written assuming thedatabase..
1) select count(*) from customer where balance >500
2)select cus_code,cus_balance from customer where purchase='false'
3)select sum(balance) as 'TOTAL BALANCE',min(balance) as 'Minimum Balance',max(balance) as 'Maximum Balance',avg(balance) as 'Average Balance' from Custpomers
4)select P_Descript,P_QOH,P_PRICE,P_QOH*P_PRICE as 'Subtotal' from Customer order by P_Descipt
5)select cus_code,cus_balance from customer where purchase='true'
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.