cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Table grand total issue (division generates avg total and not a sum)

Hi All

 

When I create a measure that calculates a division ("/") between two different numbers and I place it on a Table, I get the average of each result in the Grand Total row.

If I use the +,- or * signs Power Bi will calculate a sum in the total instead.

Can I get this with a divison as well?

 

My dax is: 

My new measure = SUM('CUBE'[column A])/[Measure 1])

FYI: Measure1 is only a "distinct count"

 

Example of what Power Bi does:

CitiesMy Measure
Paris22.36
Milan5.33
London11.8
Grand total13.16333

What I want:

 

CitiesMy Measure
Paris22.36
Milan5.33
London11.8
Grand total39.49
2 ACCEPTED SOLUTIONS

Accepted Solutions
Highlighted
Microsoft
Microsoft

Re: Table grand total issue (division generates avg total and not a sum)

Hi @Anonymous 

 

You may try below measure:

Measure =
IF (
    HASONEVALUE ( 'CUBE'[Cities] ),
    [My new measure],
    SUMX ( VALUES ( 'CUBE'[Cities] ), [My new measure] )
)

Regards,

Cherie

Community Support Team _ Cherie Chen
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

Highlighted
Anonymous
Not applicable

Re: Table grand total issue (division generates avg total and not a sum)

Thanks a bunch this has done the trick!

😄

View solution in original post

3 REPLIES 3
Highlighted
Microsoft
Microsoft

Re: Table grand total issue (division generates avg total and not a sum)

Hi @Anonymous 

 

You may try below measure:

Measure =
IF (
    HASONEVALUE ( 'CUBE'[Cities] ),
    [My new measure],
    SUMX ( VALUES ( 'CUBE'[Cities] ), [My new measure] )
)

Regards,

Cherie

Community Support Team _ Cherie Chen
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

Highlighted
Anonymous
Not applicable

Re: Table grand total issue (division generates avg total and not a sum)

Thanks a bunch this has done the trick!

😄

View solution in original post

Highlighted
Microsoft
Microsoft

Re: Table grand total issue (division generates avg total and not a sum)

Hi @Anonymous 

Kindly mark my answer as a solution if you feel that makes sense. 

Regards,

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

Helpful resources

Announcements
Community Blog

Community Blog

Visit our Community Blog for articles, guides, and information created by fellow community members.

Using the Community

Using the Community

Need help with the Power BI Community? Our 'Using the Community' support articles are a great place to start.

Community Summit North America

Community Summit North America

Innovate, Collaborate, Grow. The top training and networking event across the globe for Microsoft Business Applications

Power Platform 2020 release wave 2 plan

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors