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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Total in matrix

Hi all,

In Power BI I have a matrix where I would like to add total records: is there any way the total for some fields could be a lookup that gets a value I already have in the data (in the data I already have a total record, I need the matrix to show the total just for layout reasons)?
I need to obtain something like this, where the total is the value for which "subcategory1" and "subcategory2" have the same value:

Immagine.png
I successfully had this situation using Report builder for Power BI and now I'd like to replicate the format in Power BI.
Thank you!

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

Hi @Anonymous ,

 

I'm not sure how you get this visual and the total value, better to share some sample data to us if you don't have any Confidential Information.

My current thought is to create two measures to replace value columns, such as below.

Measure = IF(SELECTEDVALUE('Table'[subcategory2])="A"||SELECTEDVALUE('Table'[subcategory2])="B",BLANK(),SUM('Table'[value1]))
Measure 2 = IF(SELECTEDVALUE('Table'[subcategory2])="A"||SELECTEDVALUE('Table'[subcategory2])="B",BLANK(),SUM('Table'[value2]))

Results comparison: 

1.PNG

It's just a thought, the values may not be accurate, and later we can filter and calculate the correct values by adding some conditions.

 

Best Regards,

Jay

Community Support Team _ Jay Wang

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

Community Support Team _ Jay
If this post helps, then please consider Accept it as the solution
to help the other members find it.

View solution in original post

2 REPLIES 2
v-jayw-msft
Community Support
Community Support

Hi @Anonymous ,

 

I'm not sure how you get this visual and the total value, better to share some sample data to us if you don't have any Confidential Information.

My current thought is to create two measures to replace value columns, such as below.

Measure = IF(SELECTEDVALUE('Table'[subcategory2])="A"||SELECTEDVALUE('Table'[subcategory2])="B",BLANK(),SUM('Table'[value1]))
Measure 2 = IF(SELECTEDVALUE('Table'[subcategory2])="A"||SELECTEDVALUE('Table'[subcategory2])="B",BLANK(),SUM('Table'[value2]))

Results comparison: 

1.PNG

It's just a thought, the values may not be accurate, and later we can filter and calculate the correct values by adding some conditions.

 

Best Regards,

Jay

Community Support Team _ Jay Wang

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

Community Support Team _ Jay
If this post helps, then please consider Accept it as the solution
to help the other members find it.
Tad17
Solution Sage
Solution Sage

I don't understand the two subcategories as it makes the visual not really make sense becasue the total is totalling a subcategory two that now you cannot see. So I assume I am not understanding properly. 

 

However, my assumption would be to remove the second subcategory column and simply create a splicer to the side for the subcategory.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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