You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

exercise-03.sql 205B

123456
  1. SELECT vendor_name, COUNT(*) AS invoice_count,
  2. SUM(invoice_total) AS invoice_total_sum
  3. FROM vendors v JOIN invoices i
  4. ON v.vendor_id = i.vendor_id
  5. GROUP BY vendor_name
  6. ORDER BY invoice_count DESC