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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
SuprajaChennuru
Regular Visitor

To get average in the Total row, instead of sum

I have a matrix visual with 4 levels and the total row should show percentage Average of Score

 

Calculations Used :

1. DIV = Quantity/Target Quantity

2. Score = if DIV >1 then 1 else DIV

3. Score % = % of Score 

 

I have used the AverageX  and AverageX with HASONE functions, but, my results do not work with neither of them.  

 

SuprajaChennuru_0-1709136920284.png

 

3 REPLIES 3
gmsamborn
Super User
Super User

Hi @SuprajaChennuru 

 

Since it appears that you are doiing your division at a row level, I decided to create a calculated column and then find an average of that.

 

Calculated Column

_DIV =
VAR _Div =
    DIVIDE( 
        [Quantity], 
        [Target Quantity]
    )
VAR _Logic = 
    IF(
        _Div > 1,
        1,
        _Div
    )
RETURN
    _Logic

 

Measure

DIV = AVERAGE( Table1[_DIV] )

 

Let me know if you have any questions.

 

To get average in the Total row instead of sum.pbix

 



Proud to be a Super User!

daxformatter.com makes life EASIER!

This is giving me blanks. Please advise on something else 

Can you create a pbix for me to work with?

 

1)  Please provide sample data that covers your issue or question completely.
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...

 

2) Please show the expected outcome based on the sample data you provided.
https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523

 

3) Please explain how you would expect to get from step 1 to 2.

 

4) If possible, please show your past attempts at a solution.

 

 

I hope this helps.



Proud to be a Super User!

daxformatter.com makes life EASIER!

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

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.