Now I need to sum the val where the date is within the last 13 weeks (replicating the SQL command ‘datediff(ww,dated,getdate()) <=13’). Does anyone know how to get the date for the start of the week 13 weeks ago ? Or can think of a better way of doing this ??