The result is correct, and is precisely what you asked for.
The sum of the
price
column is
11.248
; dividing that by the number of rows (
5
) gives
2.2496
, which is the result you are getting.
The only way to get your expected value is to take the average price
per item. To do that, you need to sum the product of the quantity and price, and divide by the sum of the quantity:
SELECT Sum(quantity) As Quantity, Sum(quantity * price) / Sum(quantity) As Price FROM table_name WHERE item_ID = 1;