Home Forums SQL Server 2005 T-SQL (SS2K5) Getting records created in a particular week RE: Getting records created in a particular week
Andras Belokosztolszki
SSC-Insane
Points: 21971
More actions
December 3, 2007 at 6:06 am
#756435
You are right, (I probably need to sleep more) 🙂
A corrected version is:
DATEPART( wk, '3/12/2007' ) + (DATEPART( yyyy, '3/12/2007' )-1950) * 53
(the *53 should be on the year :), deducting 1950 will make the numbers even smaller)
Thanks,
Andras