March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi,
In my datasource (JIRA), I am getting data in following format.
This datasource shows release data which goes through milestones from P1 to P10 and status of each milestone.
Unique Key | Product Name | Release Name | Milestone | Status |
Key1 | Product A | 24.x | P1 | Approved |
Key2 | Product A | 24.x | P2 | Approved |
Key3 | Product A | 24.x | P3 | Approved |
Key4 | Product A | 24.x | P4 | Approved |
Key5 | Product A | 24.x | P5 | Approved |
Key6 | Product A | 24.x | P6 | Approved |
Key7 | Product A | 24.x | P7 | Approved |
Key8 | Product A | 24.x | P8 | Planned |
Key9 | Product A | 24.x | P9 | Planned |
Key10 | Product A | 24.x | P10 | Planned |
Key11 | Product B | 24.x | P1 | Approved |
Key12 | Product B | 24.x | P2 | Approved |
Key13 | Product B | 24.x | P3 | Approved |
Key14 | Product B | 24.x | P4 | Planned |
Key15 | Product B | 24.x | P5 | Planned |
Key16 | Product B | 24.x | P6 | Planned |
Key17 | Product B | 24.x | P7 | Planned |
Key18 | Product B | 24.x | P8 | Planned |
Key19 | Product B | 24.x | P9 | Planned |
Key20 | Product B | 25.x | P10 | Planned |
I would like to get an additional column to get the latest lifecycle status of release meaning which latest milestone is Approved.
Unique Key | Product Name | Release Name | Milestone | Status | Lifecycle Status |
Key1 | Product A | 24.x | P1 | Approved | P5 Approved |
Key2 | Product A | 24.x | P2 | Approved | P5 Approved |
Key3 | Product A | 24.x | P3 | Approved | P5 Approved |
Key4 | Product A | 24.x | P4 | Approved | P5 Approved |
Key5 | Product A | 24.x | P5 | Approved | P5 Approved |
Key6 | Product A | 24.x | P6 | Approved | P5 Approved |
Key7 | Product A | 24.x | P7 | Approved | P5 Approved |
Key8 | Product A | 24.x | P8 | Planned | P5 Approved |
Key9 | Product A | 24.x | P9 | Planned | P5 Approved |
Key10 | Product A | 24.x | P10 | Planned | P5 Approved |
Key11 | Product B | 24.x | P1 | Approved | P3 Approved |
Key12 | Product B | 24.x | P2 | Approved | P3 Approved |
Key13 | Product B | 24.x | P3 | Approved | P3 Approved |
Key14 | Product B | 24.x | P4 | Planned | P3 Approved |
Key15 | Product B | 24.x | P5 | Planned | P3 Approved |
Key16 | Product B | 24.x | P6 | Planned | P3 Approved |
Key17 | Product B | 24.x | P7 | Planned | P3 Approved |
Key18 | Product B | 24.x | P8 | Planned | P3 Approved |
Key19 | Product B | 24.x | P9 | Planned | P3 Approved |
Key20 | Product B | 25.x | P10 | Planned | P3 Approved |
Solved! Go to Solution.
Thanks for the reply from @amitchandak , please allow me to provide another insight:
Hi @malpani ,
You can try formula like below:
Lifecycle Status =
VAR CurrentProduct = Releases[Product Name]
VAR CurrentRelease = Releases[Release Name]
VAR LatestApprovedMilestone =
CALCULATE (
MAX ( Releases[Milestone] ),
FILTER (
Releases,
Releases[Product Name] = CurrentProduct
&& Releases[Release Name] = CurrentRelease
&& Releases[Status] = "Approved"
)
)
RETURN
IF (
ISBLANK ( LatestApprovedMilestone ),
BLANK (),
LatestApprovedMilestone & " Approved"
)
Best Regards,
Adamk Kong
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi,
The answer should be P7 (not P5) for Product A. This calculated column formula works
Column = CALCULATE(MAX(Data[Milestone]),FILTER(Data,Data[Product Name]=EARLIER(Data[Product Name])&&Data[Status]="Approved"))
Thanks for the reply from @amitchandak , please allow me to provide another insight:
Hi @malpani ,
You can try formula like below:
Lifecycle Status =
VAR CurrentProduct = Releases[Product Name]
VAR CurrentRelease = Releases[Release Name]
VAR LatestApprovedMilestone =
CALCULATE (
MAX ( Releases[Milestone] ),
FILTER (
Releases,
Releases[Product Name] = CurrentProduct
&& Releases[Release Name] = CurrentRelease
&& Releases[Status] = "Approved"
)
)
RETURN
IF (
ISBLANK ( LatestApprovedMilestone ),
BLANK (),
LatestApprovedMilestone & " Approved"
)
Best Regards,
Adamk Kong
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@malpani , Create a new column
Stage = right([Milestone], Len([Milestone]) -1)
Then create a measure
final status =
var _max = maxx(filter(Table, [Product Name] = earlier([Product Name]) ), [Stage])
return
maxx(filter(Table, [Product Name] = earlier([Product Name]) && [Stage] =_max) , [Status])
Power BI DAX- Earlier, I should have known Earlier: https://youtu.be/CVW6YwvHHi8
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
129 | |
90 | |
75 | |
58 | |
53 |
User | Count |
---|---|
200 | |
104 | |
101 | |
67 | |
55 |