Please note javascript is required for full website functionality.

Blog

Power BI Blog: Revisiting Formatting Negative Numbers with Brackets

22 October 2020

Welcome back to this week’s edition of the Power BI blog series.  This week, Jonathan Liau looks how to format negative currency values, including those infernal brackets.

We are finally going to take a break from my card example; let’s give that a rest for the time being.  This week, we are going to revisit a blog I wrote about a while back, how to format negative values with brackets.  

The previous blog about how to format negative values can be found here.  As a quick recap, we had to use a separate measure that uses the FORMAT function to achieve the brackets around negative number format.  As reference, here is a snippet of the code used in the measure:

(Total Profit) Formatted =

FORMAT(

        [Total Profit],

        "##,###  ; (##,###) ; -"

    )


If you recognise the formatting code style, it is because it is the same code we would use in Excel (please see Number Formatting for more information).

For example, we have the ‘Total Profit’ measure here, which is currently formatted as a ‘Whole Number’:

To change its format, we click on the measure in the Fields list on the right pane:

With the ‘Total Profit’ measure selected, navigate to the ‘Measure Tools’ tab on the Ribbon.  Then, in the Formatting group, click on the Format dropdown, but instead of choosing an option, we can type the following:

##,###  ; (##,###)

The resulting formatting change should look like this:

No need for any fancy FORMAT function here, just a change in the formatting options!

That’s it for this week! Come back next week for more on Power BI!

In the meantime, please remember we offer training in Power BI which you can find out more about here. If you wish to catch up on past articles, you can find all of our past Power BI blogs here.

Newsletter