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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
sea
Frequent Visitor

COUNT distinct value

Hello,

 

I have this tabl:

+----------------+--------+
| CUSTOMER |  TYPE |
+----------------+--------+
|   custom_   1 |     A    |
|   custom_   2 |     B    |  
|   custom_   1 |     A    |  
|   custom_   1 |     A    |  
|   custom_   2 |     B    |  
|   custom_   3 |     A    |  
|   custom_   4 |     B    |
+----------------+--------+

What formula can I do to measure how many distinct A-values are and how many different B-values are?

 

count A (custom_1, custom_3) = 2

count B (custom_2, custom_4) = 2

 

Thank you!

1 ACCEPTED SOLUTION
Anonymous
Not applicable

@sea,

Directly create a table visual as follows, and you will get the count value.
1.JPG

Of you can create a measure using DAX below.

Measure = DISTINCTCOUNT(Table[CUSTOMER])
2.JPG



Regards,
Lydia

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

@sea,

Directly create a table visual as follows, and you will get the count value.
1.JPG

Of you can create a measure using DAX below.

Measure = DISTINCTCOUNT(Table[CUSTOMER])
2.JPG



Regards,
Lydia

Hi, i'm quite new, so sorry if i'll ask somethink that is quite simple.

 

i have this data:

Capture.PNG

 

And i would like to have in one graph the count of all the -1, 0, 1 and 2 (the distinct valeu's) for every column. what is the best way to do so.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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