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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Kirilltog
New Member

how to get total avg without summarize

hi everyone! I have a problem. Im trying to get total average value in my table but i get wrong total value. 

 

Скриншот 13-09-2023 143203.jpg

 

my measure:

if(ISBLANK([AVG по перко])||ISBLANK([AVG по штатке]), blank(), DIVIDE([AVG по перко], [AVG по штатке])-1)
 
ok, no problem. i used summarize to solve my problem. 

measure: 
AVERAGEX(SUMMARIZE('2023 штатка', '2023 штатка'[Физ лицо.Код], "dfd", if(ISBLANK([AVG по перко])||ISBLANK([AVG по штатке]), blank(), DIVIDE([AVG по перко], [AVG по штатке])-1)), [dfd])
 
solution is work, but has low perfomance. Are there other high performance solutions?
1 ACCEPTED SOLUTION
v-zhangti
Community Support
Community Support

Hi, @Kirilltog 

 

I simply modelled your data and measure1 and measure2 give the same results without the need for a summary table.

Measure = IF(ISBLANK([AVG1])||ISBLANK([AVG2]),BLANK(),DIVIDE([AVG1],[AVG2]-1))
Measure 1 = 
AVERAGEX(SUMMARIZE('Table','Table'[Type],"dfd",IF(ISBLANK([AVG1])||ISBLANK([AVG2]),BLANK(),DIVIDE([AVG1],[AVG2]-1))),[dfd])
Measure 2 = AVERAGEX('Table',IF(ISBLANK([AVG1])||ISBLANK([AVG2]),BLANK(),DIVIDE([AVG1],[AVG2]-1)))

vzhangti_0-1694762977952.png

Is this the result you expect?

 

Best Regards,

Community Support Team _Charlotte

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-zhangti
Community Support
Community Support

Hi, @Kirilltog 

 

I simply modelled your data and measure1 and measure2 give the same results without the need for a summary table.

Measure = IF(ISBLANK([AVG1])||ISBLANK([AVG2]),BLANK(),DIVIDE([AVG1],[AVG2]-1))
Measure 1 = 
AVERAGEX(SUMMARIZE('Table','Table'[Type],"dfd",IF(ISBLANK([AVG1])||ISBLANK([AVG2]),BLANK(),DIVIDE([AVG1],[AVG2]-1))),[dfd])
Measure 2 = AVERAGEX('Table',IF(ISBLANK([AVG1])||ISBLANK([AVG2]),BLANK(),DIVIDE([AVG1],[AVG2]-1)))

vzhangti_0-1694762977952.png

Is this the result you expect?

 

Best Regards,

Community Support Team _Charlotte

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

 

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

Top Kudoed Authors