Forum Discussion
Calculate Percentage of Non Numeric(text) Column
Hi spriyanshu ,
I'm still not sure what you want, I created a simple for testing.
Suppose the slicer's field content is April 2022.
Count the number of successes in the "SUPP Benchmark" field.
Success count =
VAR _value = CALCULATE(COUNTROWS('Table'),FILTER('Table','Table'[Status]="Success"))
RETURN
IF(_value<>0,_value,0)
percentage in success against total number of success and failure in same field.
Ratio =
VAR _value = CALCULATE(COUNTROWS('Table'),FILTER('Table','Table'[SUPP Benchmark]="failure"))
RETURN
DIVIDE([Success count],_value)
Chang the format of the measure.
Attach the PBIX file for reference. Hope it helps.
If this doesn't work for you or I misunderstand your needs, please consider sharing more details about it. And it would be great if there was a sample file without any sensitive information here.
It makes it easier to give you a solution.
- Sample (dummy dataset) data as text, use the table tool in the editing bar.
- Expected output from sample data.
- Explanation in words of how to get from 1. to 2.
Here are some references that may be helpful.
How to Get Your Question Answered Quickly
Best Regards,
Community Support Team_Gao
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data
This is just the idea i am giving about the benchmark, the actual calcualtion again depend on different calculated columns
Dax for Benchmark:
SupplierDateStatus
|