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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
Niharika24
Frequent Visitor

how to add percentage column in the end of the matrix table.

percentage of grand total

percentage.PNG

1 ACCEPTED SOLUTION
Icey
Community Support
Community Support

Hi @Niharika24 ,

 

Please check if this could meet your requirements.

Measure =
VAR Count_ =
    COUNT ( 'Finding RAC-combine'[QOID] )
VAR CountAll_ =
    CALCULATE ( COUNT ( 'Finding RAC-combine'[QOID] ), ALLSELECTED () )
RETURN
    IF (
        HASONEVALUE ( 'Finding RAC-combine'[Sub Themes] )
            && HASONEVALUE ( 'Finding RAC-combine'[Area] ),
        Count_,
        COUNT_ & ", "
            & DIVIDE ( Count_, CountAll_ ) * 100 & "%"
    )

 

Icey_0-1642151363729.png

 

 

Best Regards,

Icey

 

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

View solution in original post

5 REPLIES 5
Icey
Community Support
Community Support

Hi @Niharika24 ,

 

Please check if this could meet your requirements.

Measure =
VAR Count_ =
    COUNT ( 'Finding RAC-combine'[QOID] )
VAR CountAll_ =
    CALCULATE ( COUNT ( 'Finding RAC-combine'[QOID] ), ALLSELECTED () )
RETURN
    IF (
        HASONEVALUE ( 'Finding RAC-combine'[Sub Themes] )
            && HASONEVALUE ( 'Finding RAC-combine'[Area] ),
        Count_,
        COUNT_ & ", "
            & DIVIDE ( Count_, CountAll_ ) * 100 & "%"
    )

 

Icey_0-1642151363729.png

 

 

Best Regards,

Icey

 

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

thank you for your solution! Can I ask a few questions please?
1) My percentage has 14 decimals! how can I change it to 2 only? (I already tried to edit the formatting ribbon on top)
2) There is 1 row where no percentage is showing, maybe because there was only 1 number in that row? Do you know how to fix this please? 

Smart workaround

😀

amitchandak
Super User
Super User

@Niharika24 , on is you can change total using isinscope

 

if(not(isinscope([Area])) ,[% Measure], [Measure])

 

Otherwise check work around

if you are looking for a Hybrid display with Matrix Column and measure
https://community.powerbi.com/t5/Community-Blog/Creating-a-custom-or-hybrid-matrix-in-PowerBI/ba-p/1...
https://community.powerbi.com/t5/Quick-Measures-Gallery/The-New-Hotness-Custom-Matrix-Hierarchy/m-p/...

vote for Hybrid Table
https://ideas.powerbi.com/ideas/idea/?ideaid=9bc32b23-1eb1-4e74-8b34-349887b37ebc

Join us as experts from around the world come together to shape the future of data and AI!
At the Microsoft Analytics Community Conference, global leaders and influential voices are stepping up to share their knowledge and help you master the latest in Microsoft Fabric, Copilot, and Purview.
️ November 12th-14th, 2024
 Online Event
Register Here

is this a DAX formula? could you please type all of it?

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.