# Related Sites > SQL Course >  Course 2, HAVING clause, Exercise 3

## davesommers

I believe the answer is wrong for Exercise 3 on page 5 of SQLcourse2 dealing with the HAVING clause.  The question asks to, 

"Select the customerid, number of orders they made, and the sum of their orders if they purchased more than 1 *item*."  
It doesn't ask if they made more than one *purchase*.  Therefore, I believe the answer should be like this:

SELECT customerid, COUNT(customerid), SUM(price)
FROM items_ordered
GROUP BY customerid
HAVING SUM(quantity) > 1;

Instead of counting the customerid, you should sum the quantity, which does include a person who ordered only once, but bought more than one item.

----------

