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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

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
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.