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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
Anjali_mm
Frequent Visitor

Total wrong

Experts,

I need some help to understand why my column total (from measures) is wrong ?

 

TIA

Anjali_mm_0-1641421068148.png

 

 

 

1 ACCEPTED SOLUTION
ValtteriN
Super User
Super User

Hi,

By default the total calculation applies your measure logic to itself. It seems you are using RANKX here?
To get around this issue you can create a new measure which has a custom logic for totals. 

Example dax:

Custom total rank =
if(SELECTEDVALUE(Ranking[Employee])<>BLANK(),[Ranking],CALCULATE(SUMX(ALL(Ranking),[Ranking])))
 
End result with the new measure in addition to the old [Ranking]:
ValtteriN_0-1641422552062.png

I hope this helps and if it does consider accepting this as a solution and giving the post a thumbs up!





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

2 REPLIES 2
VahidDM
Super User
Super User

Hi @Anjali_mm 

 

There are 2 watys to correct total value:

 

1- Create a rank as a calculated column not a measure

2- Use if and add different formula for total (same as @ValtteriN  solution)

 

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
LinkedIn: 
www.linkedin.com/in/vahid-dm/

 

 

ValtteriN
Super User
Super User

Hi,

By default the total calculation applies your measure logic to itself. It seems you are using RANKX here?
To get around this issue you can create a new measure which has a custom logic for totals. 

Example dax:

Custom total rank =
if(SELECTEDVALUE(Ranking[Employee])<>BLANK(),[Ranking],CALCULATE(SUMX(ALL(Ranking),[Ranking])))
 
End result with the new measure in addition to the old [Ranking]:
ValtteriN_0-1641422552062.png

I hope this helps and if it does consider accepting this as a solution and giving the post a thumbs up!





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

Top Solution Authors