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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Cervo114
Frequent Visitor

Total incorrect

I have a column that calculates the margin as a percentage, between some columns. In the total I would like you to average the margin between all the rows, instead also in the total row, it calculates the percentage between the columns. How could I do? Thanks in advance

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

Hi @Cervo114 ,

According to your description, I create a sample.

vkalyjmsft_0-1655458696430.png

The average can't get the correct result in the Total.

vkalyjmsft_1-1655458789386.png

Here's my solution, create a new measure.

Measure =
IF (
    ISINSCOPE ( 'Table'[Column1] ),
    [Average],
    SUMX ( VALUES ( 'Table'[Column1] ), [Average] )
)

Get the correct result.

vkalyjmsft_2-1655459049012.png

I attach my sample below for reference.

 

Best Regards,
Community Support Team _ kalyj

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-yanjiang-msft
Community Support
Community Support

Hi @Cervo114 ,

According to your description, I create a sample.

vkalyjmsft_0-1655458696430.png

The average can't get the correct result in the Total.

vkalyjmsft_1-1655458789386.png

Here's my solution, create a new measure.

Measure =
IF (
    ISINSCOPE ( 'Table'[Column1] ),
    [Average],
    SUMX ( VALUES ( 'Table'[Column1] ), [Average] )
)

Get the correct result.

vkalyjmsft_2-1655459049012.png

I attach my sample below for reference.

 

Best Regards,
Community Support Team _ kalyj

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

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!

December 2024

A Year in Review - December 2024

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