Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I have a manufacturing related column "Status" which has the values "Completed","Machine break","Maintenance",etc., I need to create a measure which gives the overall completed %.
If there are 10 rows and the Status field is "Completed" for around 7 rows, then my measure should be 70%.
How to do this ? Please help
Solved! Go to Solution.
@Anonymous , Try new measures like
Over all Completed % =
divide(calculate(countrows(Table), Table[Status] ="Completed"), calculate(countrows(Table)))
when you view by status
Status % = divide(calculate(countrows(Table)), calculate(countrows(Table), all(Table)))
@Anonymous , Try new measures like
Over all Completed % =
divide(calculate(countrows(Table), Table[Status] ="Completed"), calculate(countrows(Table)))
when you view by status
Status % = divide(calculate(countrows(Table)), calculate(countrows(Table), all(Table)))
@Anonymous Sample data would make this easier. In theory:
Measure =
VAR __Machine = MAX([Machine])
VAR __Completed = COUNTROWS(FILTER(ALL('Table'),[Machine]=__Machine && [Status]="Completed"))
VAR __All = COUNTROWS(FILTER(ALL('Table'),[Machine]=__Machine))
RETURN
DIVIDE(__Completed,__All,0)
You might also be interested in MTBF - See my article on Mean Time Between Failure (MTBF) which uses EARLIER: http://community.powerbi.com/t5/Community-Blog/Mean-Time-Between-Failure-MTBF-and-Power-BI/ba-p/339586.
The basic pattern is:
Column =
VAR __Current = [Value]
VAR __PreviousDate = MAXX(FILTER('Table','Table'[Date] < EARLIER('Table'[Date])),[Date])
VAR __Previous = MAXX(FILTER('Table',[Date]=__PreviousDate),[Value])
RETURN
__Current - __Previous
@Anonymous - That was for a measure to figure out what machine you are dealing with. Is this supposed to be a column?
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 58 | |
| 45 | |
| 41 | |
| 21 | |
| 18 |