Forum Discussion
Marking first instance for multiple items
Hi PowerBI Community!
I have a question that hopefully someone can help me out with. I need to mark the first instance when a “job” goes to 100% complete. There are multiple jobs in the dataset and each one needs to be marked only on the first instance that it reaches 100% complete.
Example of the current dataset looks like this:
Basically I need another column with the marks the first instance only of a job reaching 100%:
Thank you in advance!
NutNick1982 solution attached
I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos whoever helped to solve your problem. It is a token of appreciation!
⚡Visit us at https://perytus.com, your one-stop shop for Power BI related projects/training/consultancy.⚡
5 Replies
- parry2kSuper User
NutNick1982 add a new meaure like this
First Reached to 100% = VAR __date = CALCULATE ( MIN ( Table[Date] ), ALLEXCEPT ( Table, Table[JobId] ), Table[PerentComplete] = 1 ) RETURN IF ( __date = CALCULATE ( MIN ( Table[Date] ), ALLEXCEPT ( Table, Table[JobId] ), Table[PerentComplete] = 1 ), "Yes" )I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos whoever helped to solve your problem. It is a token of appreciation!
⚡Visit us at https://perytus.com, your one-stop shop for Power BI related projects/training/consultancy.⚡
- NutNick1982Helper I
Thank you for your reply. I'm getting "Yes" for all results.
Results in my Table:
Measure that I input:
- parry2kSuper User
NutNick1982 seems like I missed something, will try to reproduce at my end or if you can send pbix with sample data, it will be very helpful.
- NutNick1982Helper I
It doesn't allow me to share the file on the forum..... the sample data i used to test your measure is below:
DateJob IDPercent Complete
5/31/2019 1A 90% 5/31/2019 2B 80% 6/30/2019 1A 95% 6/30/2019 2B 85% 7/31/2019 1A 99% 7/31/2019 2B 90% 8/31/2019 1A 100% 8/31/2019 2B 95% 9/30/2019 1A 100% 9/30/2019 2B 99% 10/31/2019 1A 100% 10/31/2019 2B 100% 11/30/2019 1A 100% 11/30/2019 2B 100% 12/31/2019 1A 100% 12/31/2019 2B 100%