Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hello
Instead of showing the percetage by month, how do I show, for example Jan at 100% and the Feb at 90%....?
Thanks
Ross
Solved! Go to Solution.
Create two calculate columns and a measure using dax as below:
Calculate Columns:
RankID = SWITCH(Dates[Month Name], "January", 1, "February", 2, "March", 3, "April", 4, "May", 5, "June", 6, "July", 7, "August", 8, "September", 9, "October", 10, "November", 11, "December", 12)
Running Total = CALCULATE(SUM(Dates[Working Hours]), FILTER(Dates, Dates[RankID] >= EARLIER(Dates[RankID])))
Measure:
Percentage = MAX(Dates[Running Total]) / CALCULATE(SUM(Dates[Working Hours]), ALL(Dates))
The result will be like below:
You can refer to the attached pbix.
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
I'm confused on your description, could you please clarify more details about your requirement and share some sample data?
Regards,
Jimmy Tao
Hi @v-yuta-msft
From the attached, I was looking to get Jan being at 100% then we move into Feb the working hours left in the year would 91.13% and so on....
Does that makes sense?
Thanks
Ross
Create two calculate columns and a measure using dax as below:
Calculate Columns:
RankID = SWITCH(Dates[Month Name], "January", 1, "February", 2, "March", 3, "April", 4, "May", 5, "June", 6, "July", 7, "August", 8, "September", 9, "October", 10, "November", 11, "December", 12)
Running Total = CALCULATE(SUM(Dates[Working Hours]), FILTER(Dates, Dates[RankID] >= EARLIER(Dates[RankID])))
Measure:
Percentage = MAX(Dates[Running Total]) / CALCULATE(SUM(Dates[Working Hours]), ALL(Dates))
The result will be like below:
You can refer to the attached pbix.
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.