Use the BOL (Microsoft Books OnLine) and look up 'SET DATEFIRST'. You can use that to set the first day of the week to Saturday. I suggest that your code set it to Saturday at the beginning and then at the end set it back to what it currently is. You can 'capture' the current first day of the week with @@DATEFIRST.
-SQLBill
The following is part of my signature block and is only intended to be informational.
Posting advice: FAQ481-4875
This will not depend on your DateFirst setting. It does depend on the fact that Jan 1, 1900 is a Monday, but even the best "History Re-writers" can't touch this!
-George
Microsoft SQL Server MVP My Blogs SQLCop twitter
"The great things about standards is that there are so many to choose from." - Fortune Cookie Wisdom
-George
Microsoft SQL Server MVP My Blogs SQLCop twitter
"The great things about standards is that there are so many to choose from." - Fortune Cookie Wisdom
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.