cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
jay_patel
Helper III
Helper III

Want week Number from 1 for those months also where week starting from saturday or sunday.

Hi experts

 

Here is my graph as you can see in attached picture and selected month year is 'MAY-2021' where week 1 started from saturday so they dont have sales in week 1, however I want to consider from week 1 only. In the second screenshot you can see I am extracting WEEK NO from Transaction date, So is there any way where i can consider week 2 as week 1 and so on for the months that dont have sales in 1st week.

 

Thanks & RegardsMIS 1.PNGweek of the month.png

1 ACCEPTED SOLUTION
v-kelly-msft
Community Support
Community Support

Hi @jay_patel ,

 

Create a column with dax expression as below:

Adjusted week no = 
var _firstday=STARTOFMONTH('Table'[Date])
var _weekday=WEEKDAY(_firstday,2)
Return
IF(_weekday=6||_weekday=7,
  IF('Table'[Week month]=1,BLANK(),"Week"&('Table'[Week month]-1)),
   "Week"&'Table'[Week month])

Then you would see:(Remember to modify the data type of "Week month" to whole number)

v-kelly-msft_0-1623655016105.png

For the related .pbix file,pls see attached.

 

Best Regards,
Kelly

Did I answer your question? Mark my post as a solution!

 

View solution in original post

1 REPLY 1
v-kelly-msft
Community Support
Community Support

Hi @jay_patel ,

 

Create a column with dax expression as below:

Adjusted week no = 
var _firstday=STARTOFMONTH('Table'[Date])
var _weekday=WEEKDAY(_firstday,2)
Return
IF(_weekday=6||_weekday=7,
  IF('Table'[Week month]=1,BLANK(),"Week"&('Table'[Week month]-1)),
   "Week"&'Table'[Week month])

Then you would see:(Remember to modify the data type of "Week month" to whole number)

v-kelly-msft_0-1623655016105.png

For the related .pbix file,pls see attached.

 

Best Regards,
Kelly

Did I answer your question? Mark my post as a solution!

 

View solution in original post

Helpful resources

Announcements
PBI_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

MBAS on Demand

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Get Ready for Power BI Dev Camp

Microsoft named a Leader in The Forrester Wave

Microsoft received the highest score of any vendor in both the strategy and current offering categories.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Top Kudoed Authors