There was an error while loading. Please reload this page.
1 parent d8b7a00 commit f44575eCopy full SHA for f44575e
invoices-per-country.sql
@@ -0,0 +1,5 @@
1
+SELECT co.country_name, count(*), AVG(i.total_price)
2
+FROM country co, city ci, customer cu, invoice i
3
+WHERE co.id = ci.country_id AND ci.id = cu.city_id AND cu.id = i.customer_id
4
+GROUP BY co.country name
5
+HAVING AVG(i.total_price) > (SELECT AVG(total price))
0 commit comments