in reply to Simple query
in thread Perl/MySQL ?

Your SQL is incorrect since there is no "group by" expression used in conjuction with the aggregate function:
SELECT category, SUM(fee) FROM tblproducts /* optional where clause */ GROUP BY category
would be correct.

rdfield