This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreLevel up your Power BI skills this month - build one visual each week and tell better stories with data! Get started
Hello,
I'm trying to create a column with custom week numbers (Operating periods) that end in the dates below:
1/1/2022 - 1/12/2022 - Week 1
1/13/2022 - 1/19/2022 - Week 2
1/20/2022 - 1/26/2022 - Week 3
Until the last week of the year.
Any ideas on how I can accomplish this? I a pprecite your help!
Solved! Go to Solution.
To close the loop on this, this is what ended up working:
Operating Period = WEEKNUM('Calendar'[Date]+4, 21)-1
It gave me this:
To correct the first 5 days of the week that defaulted to Operating Period 0, I added this:
Operating Periods = if('Calendar'[Operating Period] = 0,1,WEEKNUM('Calendar'[Date]+4, 21)-1)
The result was this, which is what I needed:
To close the loop on this, this is what ended up working:
Operating Period = WEEKNUM('Calendar'[Date]+4, 21)-1
It gave me this:
To correct the first 5 days of the week that defaulted to Operating Period 0, I added this:
Operating Periods = if('Calendar'[Operating Period] = 0,1,WEEKNUM('Calendar'[Date]+4, 21)-1)
The result was this, which is what I needed:
@NPC What is the pattern? Is the first week 1/1 - 1/12 and then each week is the next 7 days? You could do something like maybe: WEEKNUM([Date],14) ? 14 starts weeks on Thursday.
Unfortunatley with this approach week 1 ends on 1/5. To answer your question though, yes - each week is the next 7 days after the first 12 days of the year.
Check out the April 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 11 | |
| 9 | |
| 9 | |
| 8 | |
| 8 |
| User | Count |
|---|---|
| 48 | |
| 27 | |
| 25 | |
| 24 | |
| 22 |