The described function (WEEKNUM) does not support weeks starting with Saturday, common in various Muslim countries including Iran.

Extend the function so that it includes a value for "weekday-start-flag" that counts weeks that start with Saturday.

Part 4, 3.17.7.342

te

Proposed Disposition of DIS 29500 Comment IR-0004 (Modified: 2008-01-11) We agree that the issue raised is valid , . We also intend extending the specification to allow for the week numbering system detailed in ISO 8601, in addition to the existing system. We and propose the following changes be made: Part 4, §3.17.7.342, page 2,820, line 1 Description: Computes the week number of the date corresponding to serial-value. The function allows two number systems: System 1: The week containing January 1 is the first week of the year, and is numbered week 1. System 2: The week containing the first Thursday of the year is the first week of the year, and is numbered as week 1 (as specified in ISO 8601). Arguments: Name Type Description weekday-start-flag number When truncated to integer, indicates the weekday on which the week begins, as follows: weekday-start-flag Meaning Number System 1 or omitted Week begins on Sunday. System 1 2 Week begins on Monday. System 1 11 Week begins on Monday. System 1 12 Week begins on Tuesday. System 1 13 Week begins on Wednesday. System 1 14 Week begins on Thursday. System 1 15 Week begins on System 1 Name Type Description Friday. 16 Week begins on Saturday. System 1 17 Week begins on Sunday. System 1 21 Week begins on Monday. System 2 Part 4, §3.17.7.342, page 2,820, lines 9­12 [Example: WEEKNUM(DATE(2006,1,1) results in 1 WEEKNUM(DATE(2006,1,1),1) results in 1 WEEKNUM(DATE(2006,1,1),17) results in 1 WEEKNUM(DATE(2006,1,1),21) results in 1 WEEKNUM(DATE(2006,2,1),1) results in 5 WEEKNUM(DATE(2006,2,1),2) results in 6 WEEKNUM(DATE(2006,2,1),11) results in 6 end example]

Tag and Go

No Comments

Leave a comment

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>

  • Argentina (1)
  • Australia (30)
  • Austria (1)
  • Belgium (1)
  • Brazil (64)
  • Bulgaria (3)
  • Canada (79)
  • Chile (217)
  • China (1)
  • Colombia (237)
  • Czech Republic (75)
  • Denmark (168)
  • Ecma (76)
  • Ecuador (1)
  • Finland (15)
  • France (592)
  • Germany (162)
  • Ghana (12)
  • Greece (113)
  • India (82)
  • Iran (58)
  • Ireland (12)
  • Israel (33)
  • Italy (2)
  • Japan (82)
  • Jordan (1)
  • Kenya (81)
  • Malaysia (23)
  • Malta (5)
  • Mexico (7)
  • New Zealand (54)
  • Norway (12)
  • Peru (10)
  • Philippines (7)
  • Poland (4)
  • Portugal (118)
  • Singapore (2)
  • South Africa (17)
  • South Korea (25)
  • Spain (1)
  • Switzerland (19)
  • Thailand (1)
  • Tunisia (3)
  • Turkey (1)
  • UK (635)
  • Uruguay (18)
  • USA (288)
  • Venezuela (73)