carlos9742 carlos9742
  • 17-12-2020
  • Computers and Technology
contestada

Write a query to find the customer balance summary (total, min, max, avg) for all customers who have not made purchases during the current invoicing period

Respuesta :

IfeanyiEze8899 IfeanyiEze8899
  • 19-12-2020

Answer:

SELECT SUM(customer_balance) as Total, MIN(customer_balance) as minimum_balance, Max(customer_balance) as maximum_balance, AVG(customer_balance) as average_balance FROM customers WHERE customer_id NOT IN (SELECT customer_id FROM invoice)

Explanation:

The SQL query statement returns four columns which are aggregates of the column customer_balance from the customers table in the database and the rows are for customers that have not made any purchase during the current invoicing period.

Answer Link

Otras preguntas

a student says that 6.42 x 10 to the 5 power is greater han 78.1 x 10 to the 4 power
How do you solve 17 = 11y + 12x 12x + 11y = 14 in subsitution method?
A computer technician charges $40.00 per hour plus $65.00 service charge. The computer technician spends h hours to complete the job. Complete the function that
a^2+2ab+b^2. solve for a=10 and b=50
A 200 g hockey puck is launched up a metal ramp that is inclined at a 30° angle. the coefficients of static and kinetic friction between the hockey puck and the
Where does the governments power to govern come from?
Word 2013 opens, by default, on a blank document?
Cuál es tu respuesta
help me with this, pls
A parent, smiling and laughing, is moving a small stuffed toy back and forth in front of a 7-week-old infant. the most likely reaction the parent will receive f