Returns the week number in the year.
A date in datetime format.
A number that determines the return value: for example, use 1 when week begins on Sunday, or use 2 when week begins on Monday, or use 21 for ISO week numbers. More details in Remarks section.
The week number for the given date.
If the argument is a string, it is translated into a datetime value using the same rules applied by the DATEVALUE function.
There are two systems used for this function:
- 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. This system is the methodology specified in ISO 8601, which is commonly known as the European week numbering system.
|Return_type||Week begins on||System|
|1 or omitted||Sunday||1|
Other related functions are:
Contributors: Alberto Ferrari, Marco Russo, Daniil Maslyuk
MSDN documentation: https://docs.microsoft.com/en-us/dax/weeknum-function-dax