Thanks Portuga. I took your advice and found some additional ideas that do work, but requires the extra column with the =year function. This is the formula that works:

{=SUM((J5:J300=2007)*(Q5:Q300=1))}

I wish I could do without the =year column though. If anybody knows a better way please do tell.