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
CApowerbi
Frequent Visitor

Wrong table total

Hello!
I reach out to you in hopes to get help here. 

I have tables where the total does not sum up the correct way. See example: 

 

CApowerbi_2-1684918918033.png

 

The red area to the left= The companies in our business. 


As you can see I have highlited the total rows which is not sum up the correct way. 
The "average lönekostnad ex soc" is not supposed to be in the table, but I brought it in here since I use it in the measure for "total lönekostnad ex soc". The total row in "Total lönekostnad ex soc" is multiplying "antal konsulter"=208 x "Average lönekostnad ex soc"=-45001,75. 
This is not correct. I want the "total lönekostnad ex soc" total row to summarize the total for the rows that is over it. 

 

This is the measure I use for the "total lönekostnad ex soc":

Total lönekostnad ex. soc = [Average lönekostnad ex soc]* [Antal konsulter]


Do you understand my problem? 

Hope that you can help me! 

Best regards! 

 

 

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

Hi @CApowerbi ,

 

I suggest you to use SUMX() function to create a new measure based on [Average lönekostnad ex soc].

New Average lönekostnad ex soc =
SUMX (
    VALUES ( 'TableName'[ColumnName on Matrix Row] ),
    [Average lönekostnad ex soc]
)
Total lönekostnad ex. soc =
[New Average lönekostnad ex soc] * [Antal konsulter]

 

Best Regards,
Rico Zhou

 

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

1 REPLY 1
v-eqin-msft
Community Support
Community Support

Hi @CApowerbi ,

 

I suggest you to use SUMX() function to create a new measure based on [Average lönekostnad ex soc].

New Average lönekostnad ex soc =
SUMX (
    VALUES ( 'TableName'[ColumnName on Matrix Row] ),
    [Average lönekostnad ex soc]
)
Total lönekostnad ex. soc =
[New Average lönekostnad ex soc] * [Antal konsulter]

 

Best Regards,
Rico Zhou

 

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

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.