Forum Discussion
Calculating slippage
Hi All,
I have a bunch of projects and there various milestone dates in a table that looks something like this:
| Project ID | Milestone A | Milestone B | Row created on |
| 1 | 27/10/20 | 31/12/20 | 01/1/20 |
| 1 | 23/10/20 | 31/12/20 | 03/1/20 |
| 1 | 16/10/20 | 05/1/21 | 09/1/20 |
| 2 | 27/8/20 | 31/11/20 | 22/12/19 |
| 2 | 23/8/20 | 31/11/20 | 24/12/19 |
| 2 | 16/8/20 | 07/1/21 | 01/1/20 |
I am trying to work out the slippage for each milestone, for each project, by finding the earliest and latest created instance of each milestone and then calculating the difference between the two.
8 Replies
- amitchandakSuper User
Try
1 = minx(filter(table,projectid = earlier(projectid) && projectdate <earlier(projectdate), projectdate) 2 = maxx(filter(table,projectid = earlier(projectid) && projectdate >earlier(projectdate), projectdate)- AnonymousNot applicable
Hi thanks for taking the time to reply. Unfortunately I am getting an error message, too many arguments passed to the filter function. Would this solution correctly identify the earliest created entry? Just asking because later entries might have earlier dates if the deadline comes forward.
- amitchandakSuper User
Missing syntax
1 = minx(filter(table,projectid = earlier(projectid) && projectdate <earlier(projectdate), projectdate)) 2 = maxx(filter(table,projectid = earlier(projectid) && projectdate >earlier(projectdate), projectdate))Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution. In case it does not help, please provide additional information and mark me with @
Thanks. My Recent Blog -
https://community.powerbi.com/t5/Community-Blog/Winner-Topper-on-Map-How-to-Color-States-on-a-Map-with-Winners/ba-p/890814
https://community.powerbi.com/t5/Community-Blog/HR-Analytics-Active-Employee-Hire-and-Termination-trend/ba-p/882970
https://community.powerbi.com/t5/Community-Blog/Power-BI-Working-with-Non-Standard-Time-Periods/ba-p/881739
https://community.powerbi.com/t5/Community-Blog/Comparing-Data-Across-Date-Ranges/ba-p/823601
- v-juanli-msftCommunity Support
Hi Anonymous
Is this problem sloved?If it is sloved, could you kindly accept it as a solution to close this case?If not, please let me know.Best RegardsMaggie- AnonymousNot applicable
Hi Maggie,
This is not solved yet, sorry for the delay. I have posted again as a follow on.
- v-juanli-msftCommunity Support
Hi Anonymous
I don't find any data about 2020/10/27.
Could you explain more for this?
Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.