Question: how many customers have 7 or more orders
SQL: SELECT count ( * )  FROM  ( SELECT * FROM customers AS T1 JOIN invoices AS T2 ON T2.customer_id   =   T1.id GROUP BY T1.id having count ( * )   > =   7 )