Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Wanted to Show Month Week Number ( For Ex :- June Week 1, June Week 2 .. etc , March Week 1 )

Hi Team,

 

I have date column in Power BI which shows every Monday of the week, Now I wanted to create a column which will show June Week 1, June Week 2 ... December Week 1.

 

If i use Weeknum then it is giving me numbers from 1 to 53 which i dont want.

 

Could you please help me resolve it.

 

Thanks,

Shubham

 

1 ACCEPTED SOLUTION
Fowmy
Super User
Super User

@Anonymous 

Add this as a new column

Month-Week = 
VAR _DAY = DAY([Date]) RETURN

SWITCH( TRUE(),
    _DAY >= 1 && _DAY <= 7, "Week 1",
    _DAY >= 8 && _DAY <= 14, "Week 2",
    _DAY >= 15 && _DAY <= 21, "Week 3",
    _DAY >= 22 && _DAY <= 28, "Week 4",
    "Week 5"
)

Fowmy_0-1601323792444.png

________________________

If my answer was helpful, please consider Accept it as the solution to help the other members find it

Click on the Thumbs-Up icon if you like this reply 🙂

YouTube  LinkedIn

 




Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

3 REPLIES 3
Fowmy
Super User
Super User

@Anonymous 

Add this as a new column

Month-Week = 
VAR _DAY = DAY([Date]) RETURN

SWITCH( TRUE(),
    _DAY >= 1 && _DAY <= 7, "Week 1",
    _DAY >= 8 && _DAY <= 14, "Week 2",
    _DAY >= 15 && _DAY <= 21, "Week 3",
    _DAY >= 22 && _DAY <= 28, "Week 4",
    "Week 5"
)

Fowmy_0-1601323792444.png

________________________

If my answer was helpful, please consider Accept it as the solution to help the other members find it

Click on the Thumbs-Up icon if you like this reply 🙂

YouTube  LinkedIn

 




Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

Sumanth_23
Memorable Member
Memorable Member

hi @Anonymous  - you can create a calucalated column in your date table as shown below 

 

Month = FORMAT([Date], "MMMM")
Month-Week-No = 'Calendar'[Month] & " " & "Week " & WEEKNUM('Calendar'[Date])
 
Month-Week-No.png
Please mark the post as a solution and provide a 👍 if my comment helped with solving your issue. Thanks!
Did I answer your question? Mark my post as a solution! Appreciate your Kudos!

Proud to be a Super User!



Anonymous
Not applicable

Thanks for the reply. But in this case, in february it will show February Week 5  , i dont want that, for every new month counting should start from Week 1. 

 

ShubhamK_0-1601323111886.png

Thanks,

Shubham

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.