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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Measure to calculate the sum of distinct count

Hi everyone,

 

I would like to show the sum of distinct count on a column chart. My data looks like this.

Pheroxiz_0-1627534497517.png

What I would like to achieve is a graph that shows the sum of the distinct count of ID for each customer. Here I can show you the summary table and the result chart. Actually, the summary table is not needed. A measure that can calculate the sum of the distinct count of ID for each customer is ok.

Pheroxiz_2-1627535059772.png

 

Pheroxiz_1-1627534874655.png

Thank you very much for your help.

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , you can try like

 

Countx(summarize(Table, Table[Month], Table[Shop], Table[Customer]),[Customer])

 

You can add or remove group column from summarize

View solution in original post

4 REPLIES 4
ryan_mayu
Super User
Super User

@Anonymous 

why the distinctcount for month1 shop1 is 4? could you pls provide the calculation logic?





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

Proud to be a Super User!




Anonymous
Not applicable

The solution provided by @amitchandak already solved my problem. Thanks for your help anyway ^-^

amitchandak
Super User
Super User

@Anonymous , you can try like

 

Countx(summarize(Table, Table[Month], Table[Shop], Table[Customer]),[Customer])

 

You can add or remove group column from summarize

Anonymous
Not applicable

Thanks for your great solution!

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.