Reply
Highlighted
Regular Visitor
Posts: 22
Registered: ‎06-06-2018
Accepted Solution

COUNT DISTINCT SHOWS WRONG GRAND TOTAL

Hey 

screeen.PNGHey My grand total is wrong when using distinct count, if the visualisation is a matrix, table or any. The grand totalt is wrong. my dax formel is 

User Distinct = DISTINCTCOUNT(table[UserId] )

There are many users who do different operations, one user can do a operation 4-5 times and etc.. but i want to have it distinct. But the sum when i filter it with a slicer or any other thing, it shows the row value correct, but the grand totalt is wrong! 

NEED HELP ASAP! 


thanx in advance, 


Accepted Solutions
Moderator
Posts: 9,137
Registered: ‎03-06-2016

Re: COUNT DISTINCT SHOWS WRONG GRAND TOTAL

Hi @GSinghking,

 

In your scenario, the measure will evaluate who column [UserId] and count distinct values on Total row of the table visual, instead of sum each measure row values. 

 

If you would like to place total of each measure value on Total row, you can modify the measure below: 

User Distinct = var t=SUMMARIZE('Table5','Table5'[Operation],"UserDistinct",DISTINCTCOUNT(Table5[UserID] ))
return
SUMX(t,[UserDistinct])

 

q1.PNG

 

Best Regards,
Qiuyun Yu 

Community Support Team _ Qiuyun Yu
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

Attachment

All Replies
Moderator
Posts: 9,137
Registered: ‎03-06-2016

Re: COUNT DISTINCT SHOWS WRONG GRAND TOTAL

Hi @GSinghking,

 

In your scenario, the measure will evaluate who column [UserId] and count distinct values on Total row of the table visual, instead of sum each measure row values. 

 

If you would like to place total of each measure value on Total row, you can modify the measure below: 

User Distinct = var t=SUMMARIZE('Table5','Table5'[Operation],"UserDistinct",DISTINCTCOUNT(Table5[UserID] ))
return
SUMX(t,[UserDistinct])

 

q1.PNG

 

Best Regards,
Qiuyun Yu 

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Attachment
Visitor
Posts: 1
Registered: ‎09-25-2018

Re: COUNT DISTINCT SHOWS WRONG GRAND TOTAL

Hi There!

 

I have to do the same but filter it between two dates using slicers as my filters 

 

for an e.g. count of distinct operations but for last week and previous last week and cannot apply the filter on the summarization though.