Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
pborah
Solution Sage
Solution Sage

I want units to be displayed properly

Case in point -

 

pborah_0-1719245511813.png

 

 

The values above have not reached millions yet and I want powerBI to stop representing it in decimal digit millions and show it as thousands instead. However when the values do reach millions, I want powerbi to switch from using thousands to millions. Currently it's in auto. But if I was to set it myself, it could only be one of thousands or millions or billions. I'm not sure how the custom option will work here. 

 

Thanks.

 

1 ACCEPTED SOLUTION
jdbuchanan71
Super User
Super User

@pborah 

Your best bet is to write a measure that handles the formatting exactly the way you want, something like this.

Paid Amount Label =
VAR _PaidAmount = [Paid Amount]
RETURN
SWITCH (
    TRUE(),
    _PaidAmount > 1000000, FORMAT ( _PaidAmount, "#,#,,.0 M"),
    _PaidAmount > 1000, FORMAT ( _PaidAmount, "#,#,.0 K"),
    FORMAT ( _PaidAmount, "#,#.00")
)

Then use that measure as your data label for the chart.

jdbuchanan71_0-1719246108301.png

 

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Hi @pborah ,

I create a table and a Stacked bar chart.

vyilongmsft_0-1719287637812.png

Then you can click on this button below.

vyilongmsft_1-1719287825148.png

vyilongmsft_2-1719287865260.png

vyilongmsft_3-1719287891574.png

 

 

 

Best Regards

Yilong Zhou

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

jdbuchanan71
Super User
Super User

No because the amounts are dynamic based on filtering and calculated columns are are only refreshed when the model is refreshed.  I have this measure running in a model that has 60 million rows in the main table and it runs fine.  The number it is formatting is just a SUM measure and that should run very quickly even over millions of rows.

jdbuchanan71
Super User
Super User

@pborah 

Your best bet is to write a measure that handles the formatting exactly the way you want, something like this.

Paid Amount Label =
VAR _PaidAmount = [Paid Amount]
RETURN
SWITCH (
    TRUE(),
    _PaidAmount > 1000000, FORMAT ( _PaidAmount, "#,#,,.0 M"),
    _PaidAmount > 1000, FORMAT ( _PaidAmount, "#,#,.0 K"),
    FORMAT ( _PaidAmount, "#,#.00")
)

Then use that measure as your data label for the chart.

jdbuchanan71_0-1719246108301.png

 

thanks @jdbuchanan71 . Will this work for a calculated column? the dataset has over a few million rows and if I can get away with just modifying the dax code for the calculated column that gives me these numbers, i'd rather not create a separate measure so I can keep the overhead to a minimum.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.