Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Week Calculations

Hi Team ,   Need help on how to calculate how many week will be there in a month. Example Month Septmber need week date like  01/09/2019 ,07/09/2019, 13/09/2019.   Thanks & Regards Shashank
  • v-xuding-msft's avatar
    6 years ago

    Hi Anonymous ,

    You could try the formulas below. The measure calculats that how many weeks in the month. If you want to get the fisrt day for per week, you could try the formula of "First day of week".

     

    Week of Month = 1 + WEEKNUM ( 'Table'[Date] ) - WEEKNUM ( STARTOFMONTH ( 'Table'[Date] ) )
    Measure = DISTINCTCOUNT('Table'[Week of Month])
    
    First day of week = ('Table'[Date]-WEEKDAY('Table'[Date],1)+1)

     

    Note:  "Week of Month" and "First day of week" are calculated columns.  I attached my sample that you can have a try.

     

    Best Regards,

    Xue Ding

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.