By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,826 Members | 2,384 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,826 IT Pros & Developers. It's quick & easy.

DatePart week problem

P: 58
I use DatePart("ww",[Time Transaction Table].Date) to get the number of the week in the year for a weekly time card.

The week in the system is beginning Sunday and ending Saturday. Is there any way to make it beginning Monday and ending Sunday?
Dec 12 '06 #1
Share this Question
Share on Google+
3 Replies


MMcCarthy
Expert Mod 10K+
P: 14,534
I use DatePart("ww",[Time Transaction Table].Date) to get the number of the week in the year for a weekly time card.

The week in the system is beginning Sunday and ending Saturday. Is there any way to make it beginning Monday and ending Sunday?
The syntax for this function is ...

Expand|Select|Wrap|Line Numbers
  1. DatePart ( interval, date, [firstdayofweek], [firstweekofyear])
  2.  
The default is 1 for Sunday and 2 would be Monday.

Therefore .....

Expand|Select|Wrap|Line Numbers
  1. DatePart ("ww",[Time Transaction Table].[Date], 2)
  2.  
Mary
Dec 12 '06 #2

P: 58
I have to tell you, this has been the biggest Access project I've ever done, and to have something come up when I'm this far into it (like the first day of the week issue) that can potentially mess up all of my work is very scary to a non-pro like me.

This was an easy fix, and it worked great. Thank you so much...you have saved my skin!

ang

The syntax for this function is ...

Expand|Select|Wrap|Line Numbers
  1. DatePart ( interval, date, [firstdayofweek], [firstweekofyear])
  2.  
The default is 1 for Sunday and 2 would be Monday.

Therefore .....

Expand|Select|Wrap|Line Numbers
  1. DatePart ("ww",[Time Transaction Table].[Date], 2)
  2.  
Mary
Dec 12 '06 #3

MMcCarthy
Expert Mod 10K+
P: 14,534
I have to tell you, this has been the biggest Access project I've ever done, and to have something come up when I'm this far into it (like the first day of the week issue) that can potentially mess up all of my work is very scary to a non-pro like me.

This was an easy fix, and it worked great. Thank you so much...you have saved my skin!

ang
You're welcome ang.

Mary
Dec 12 '06 #4

Post your reply

Sign in to post your reply or Sign up for a free account.