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.
Hi,
My data concists of work orders. For each week I count the number of work orders that are planned for the upcoming week ("planned") and the number of work orders that were planned last week, but not completed ("expired"). My table looks like this:
I need to create a measure that shows the percentage of work orders done, which takes into account the number of work orders that were not completed (shown as expired the next week).
What I suppose it should look like:
I guess it is an easy solution to this, but I run into trouble when I try to create the measure for week n-1.
Anyone able to help me on this?
Solved! Go to Solution.
Assuming you have task time. Have a separate Week /date table with Week or week Rank.
Column
Week Rank = RANKX(all('Date'),'Date'[Week Start date],,ASC,Dense)
measures
This Week = CALCULATE(sum('Table'[Tasks]), FILTER(ALL('Date'),'Date'[Week Rank]=max('Date'[Week Rank])) && Task[Type] = "Expired")
Last Week = CALCULATE(sum('Table'[Tasks]), FILTER(ALL('Date'),'Date'[Week Rank]=max('Date'[Week Rank])-1))
Percent = Divide([Last Week] -[this Week],[last Week])
refer
https://medium.com/@amitchandak.1978/power-bi-wtd-questions-time-intelligence-4-5-98c30fab69d3
https://community.powerbi.com/t5/Community-Blog/Week-Is-Not-So-Weak-WTD-Last-WTD-and-This-Week-vs-La...
Assuming you have task time. Have a separate Week /date table with Week or week Rank.
Column
Week Rank = RANKX(all('Date'),'Date'[Week Start date],,ASC,Dense)
measures
This Week = CALCULATE(sum('Table'[Tasks]), FILTER(ALL('Date'),'Date'[Week Rank]=max('Date'[Week Rank])) && Task[Type] = "Expired")
Last Week = CALCULATE(sum('Table'[Tasks]), FILTER(ALL('Date'),'Date'[Week Rank]=max('Date'[Week Rank])-1))
Percent = Divide([Last Week] -[this Week],[last Week])
refer
https://medium.com/@amitchandak.1978/power-bi-wtd-questions-time-intelligence-4-5-98c30fab69d3
https://community.powerbi.com/t5/Community-Blog/Week-Is-Not-So-Weak-WTD-Last-WTD-and-This-Week-vs-La...
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
97 | |
96 | |
81 | |
74 | |
66 |
User | Count |
---|---|
126 | |
105 | |
103 | |
81 | |
72 |