Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hi,
I have a calendar table I created in PowerQuery.
I want to add to it a column for week number with the following conditions
Using the Date.WeekOfMonth function, I was able to get the week number in months, but when the month changes, it starts from 1, which is not the way I want it.
How can I add a column to the calendar table in PowerQuery with the following conditions
-Week number of the year in total
-Monday begins on Monday and ends on Sunday
-the week number is carried forward when the month changes
-When the year changes, it starts from 1.
Thank you in advance!
Hi @umekuro ,
Have you tried using the Date.WeekOfYear function?
Date.WeekOfYear([Date], Day.Monday)
Pete
Proud to be a Datanaut!
Thank you,Pete!
Yes, I used the Date.WeekOfYear function,
but, this function returns the week number across the month, which is not what I am looking for.
I want it to replace the next week number when the month changes.
Of course, the number of week numbers per year will be more than 52, but I need such a week number.
Thanks a lot for your advice.