Forum Discussion
Units shown on visuals
- 1 year ago
Well you technically could, but then I believe it will be then considered a string as Power BI does not natively support a apostrophe as a separator.
As per the format you described, I believe you wanted it formatted based on a scale of a million. I have wriiten a basic structure, but you will need to build upon it for cases where more than 100 million or cases where it is less than 100k but it will give you a head start:Value with Apostrophe = SUBSTITUTE( FORMAT(SUM('Test Data'[Value]) / 1000000, "0.000"), ".", "'" )Here is the DAX to build the table to test it with:
Test Data = DATATABLE( "Category", STRING, "Value", INTEGER, "Description", STRING, { {"Sales", 1250000, "1.25 million"}, {"Marketing", 750000, "750 thousand"}, {"Operations", 2500000, "2.5 million"}, {"HR", 125000, "125 thousand"}, {"IT", 3750000, "3.75 million"}, {"Finance", 500000, "500 thousand"}, {"Research", 1875000, "1.875 million"}, {"Support", 625000, "625 thousand"}, {"Development", 4200000, "4.2 million"}, {"Training", 300000, "300 thousand"} } )Personally, I would recommend avoiding this but if you really need it, I hope this helps!
That is automatic for cards (Power BI chooses for you the best format based on the available space in the visual, sets to "auto"), and you can also choose to change this and decide the format you want and keep it ("none", "thousands" etc)
On visuals different from cards, you need to decide if you want to use a specifi format (it defaults to "none" but you can choose "none", "thousands" etc)
All is done through the format pane, for cards it is on the "callout values" section of the format pane, for other visuals under "specific column" section and then subsection "values"of the fomat pane
If this helped, please consider giving kudos and mark as a solution
me in replies or I'll lose your thread
Want to check your DAX skills? Answer my biweekly DAX challenges on the kubisco Linkedin page
Consider voting this Power BI idea
Francesco Bergamaschi
MBA, M.Eng, M.Econ, Professor of BI