we use many forms of this...
SUM( (case when (year = '2009' and week<=40
OR year = '2008' and week>=1) then 1 else 0
end) * myvalue ) as TYEAR
so there is a condition in the Sum function.
can infini enhance the speed where there are Case in the Sum?