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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
jayala
Frequent Visitor

Multiple values in the same cell (value and %)

Hello guys,

 

I am wondering if is there is a way to show multiple values in the same cell using a Matrix.

I have price and discounts as two separated rows and I also want to show the percentage of that discount over the price in the same cell inside brackets.

 

matrix.JPG

 

Do you know any way to do it?

 

Thank you in advance.

1 ACCEPTED SOLUTION
v-frfei-msft
Community Support
Community Support

Hi @jayala ,

 

Please create a measure as below.

Measure = 
VAR va =
    SUM ( 'Table (2)'[value] )
VAR p =
    MAX ( 'Table (2)'[p/d] )
VAR pva =
    CALCULATE (
        SUM ( 'Table (2)'[value] ),
        FILTER (
            ALLEXCEPT ( 'Table (2)', 'Table (2)'[Month] ),
            'Table (2)'[p/d] = "Price"
        )
    )
RETURN
    IF (
        p = "discounts",
        va & "("
            & FORMAT ( ROUND ( va / pva, 2 ), "Percent" ) & ")",
        va
    )

Capture.PNG

Pbix as attached.

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

View solution in original post

3 REPLIES 3
v-frfei-msft
Community Support
Community Support

Hi @jayala ,

 

Please create a measure as below.

Measure = 
VAR va =
    SUM ( 'Table (2)'[value] )
VAR p =
    MAX ( 'Table (2)'[p/d] )
VAR pva =
    CALCULATE (
        SUM ( 'Table (2)'[value] ),
        FILTER (
            ALLEXCEPT ( 'Table (2)', 'Table (2)'[Month] ),
            'Table (2)'[p/d] = "Price"
        )
    )
RETURN
    IF (
        p = "discounts",
        va & "("
            & FORMAT ( ROUND ( va / pva, 2 ), "Percent" ) & ")",
        va
    )

Capture.PNG

Pbix as attached.

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Hi @v-frfei-msft thank you for your help.

 

It looks pretty good. I will have to think my dataset structure again to implement it.

 

 

mwegener
Most Valuable Professional
Most Valuable Professional

Hi @jayala ,

 

you could create a Text Measure.

Discount Label =
IF (
    ISBLANK ( [Discount] ),
    BLANK (),
    FORMAT ( [Discount], "0" ) & " ("
        & FORMAT ( [Discount %], "0%" ) & ")"
)

Regards,

Marcus

Dortmund - Germany
If I answered your question, please mark my post as solution, this will also help others.
Please give Kudos for support.

Did I answer your question?
Please mark my post as solution, this will also help others.
Please give Kudos for support.

Marcus Wegener works as Full Stack Power BI Engineer at BI or DIE.
His mission is clear: "Get the most out of data, with Power BI."
twitter - LinkedIn - YouTube - website - podcast - Power BI Tutorials


Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.

Top Solution Authors
Top Kudoed Authors