Forum Discussion
How to get weekwise count
- Anonymous4 years ago
Hi saivina2920 ,
Here's my solution.
1.Create a calculated column to remove "_MN" and "_DN".
EmpNo without MN/DN =IF (CONTAINSSTRING ( [EmpNo], "_MN" ) = TRUE ()|| CONTAINSSTRING ( [EmpNo], "_DN" ) = TRUE (),LEFT ( [EmpNo], LEN ( [EmpNo] ) - 3 ),[EmpNo])2.Create a calendar table. And sort the Year-Weeknum column by the sort column.
Calendar =ADDCOLUMNS (CALENDAR ( MIN ( 'Table'[EmpRelieve Date] ), MAX ( 'Table'[EmpRelieve Date] ) ),"Year-WeekNum",YEAR ( [Date] ) & "-"& WEEKNUM ( [Date], 2 ),"sort",YEAR ( [Date] ) * 100+ WEEKNUM ( [Date], 2 ))3.Create the following visual. Select "Count(Distinct)".
You can check more details from my attachment.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi saivina2920 ,
Here's my solution.
1.Create a calculated column to remove "_MN" and "_DN".
2.Create a calendar table. And sort the Year-Weeknum column by the sort column.
3.Create the following visual. Select "Count(Distinct)".
You can check more details from my attachment.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
It's Perfect...