I believe this will work.declare @whatday varchar(20), @whatweek int, @whatyear char(4)set @whatday = 'monday'set @whatweek = 44set @whatyear = '2003'declare @dayofweek int, @firstofyear datetimeset @firstofyear = convert(datetime,'1/1/' + @whatyear)select @dayofweek = case when @whatday = 'monday' then 2 when @whatday = 'tuesday' then 3 when @whatday = 'wednesday' then 4 when @whatday = 'thursday' then 5 when @whatday = 'friday' then 6 when @whatday = 'saturday' then 7 when @whatday = 'sunday' then 1 endselect dateadd(dd,(datepart(weekday,(dateadd(ww,@whatweek,@firstofyear))) - @dayofweek)*-1,dateadd(ww,@whatweek,@firstofyear))