Forum Discussion
DAX Function - FORMAT( x, "Standard") need "Whole"
I am utilizing a Matrix visual to provide my main stats in a vertical format. Each stat has a value and a % to Total.
- Each stat is associated to a device.(Top Row)
- Each stat is an inidividual DAX formula. (Left hand side)
I have not figured out a way to insert both. I ended up with a formula to mimic this, but I lose formating of the value. I have tried FORMAT(x, "Standard") but it pushes it to a Decimal and I need Whole.
Formula -
- Anonymous3 years ago
Hi dal2klc ,
Please try below dax formula:
[- Metric#] = MID(FORMAT([Bad Label], "Standard"),1,LEN(FORMAT([Bad Label], "Standard"))-3) & " / " & ROUND(([Bad Label] / [Scan Volume])*100,2) & "%"))Best regards,
Community Support Team_Binbin Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
3 Replies
- AnonymousNot applicable
Hi dal2klc ,
Please try below dax formula:
[- Metric#] = MID(FORMAT([Bad Label], "Standard"),1,LEN(FORMAT([Bad Label], "Standard"))-3) & " / " & ROUND(([Bad Label] / [Scan Volume])*100,2) & "%"))Best regards,
Community Support Team_Binbin Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.- dal2klcNew Member
Thank you for your assistance, I should have thought about LEN, I appreciate your help!
- PowerBI_ScottFrequent Visitor
Would using the format #,### as shown below work better? If so, it would be easier to read/modify later.
[- Metric#] = FORMAT([Bad Label], "#,###") & " / " & ROUND(([Bad Label] / [Scan Volume])*100,2) & "%"))