In the simplest for you will have to restrict the records returned by your query to a range that includes your first and last day of the week like so 'SELECT * FROM MyTable WHERE DateField BETWEEN Date1 and Date2', where Date1 and Date2 are values you know in advance.
A combination of @@DATEFIRST and DATEADD functions should help you get the first and last date of the week in general.
Let me know if you need an example, I haven't got much time now.
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.