GROUP BY

GROUP BY

am 10.11.2006 09:42:03 von -

I can use subqueries to select from the following table to produce the
output:

Total 2004 2005 2006
----------------------------
10 2 4 4



foobar
---------------
DATE added_date



I was told that I can use GROUP BY (I think) instead.

I only managed to do the total which is

SELECT COUNT(*)
FROM foobar;



Please advice how I can get the sub count of the years.
Thank you.