Forum Discussion
Week Number calculation DAX query returning wrong results
- 5 years ago
I solved the issue but in different way.I am writing the solution so that anyone else can refer in the coming days .Instead of 2 use 21 as parameter.
WeekNumber = WEEKNUM([Date],21)
This will fetch correct results
It's a difference in how the first week of the year is handled. See the screenshot below:
The first week of January starts on Friday, so week 1 is a partial week. It sounds as if you want to define week 1 as the first week that contains a Monday. If so, you would have to create additional logic to handle this scenario.
I solved the issue but in different way.I am writing the solution so that anyone else can refer in the coming days .Instead of 2 use 21 as parameter.
WeekNumber = WEEKNUM([Date],21)
This will fetch correct results