Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Week()
Message
From
07/12/2006 14:34:34
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
07/12/2006 14:19:02
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Re: Week()
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Miscellaneous
Thread ID:
01175822
Message ID:
01175835
Views:
5
>Hi All
>
>Looking for confirmation on the usage of WEEK():
>
>I need to allocate dates within a year to a week. Simple enough using the WEEK() function. But then I came across 2004/12/31 - WEEK() returns 1 for this date, meaning the 1st week of the year 2005.
>
>How can I ensure that for any given date the week returned must always be for and within the current year i.e. a value between 1 and 53? Or should I rather just divide the day of the year by 7 and calculate the value manually?

Perhaps the command SET FWEEK helps.

"Specifies the requirements for the first week of the year."
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Reply
Map
View

Click here to load this message in the networking platform