Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello,
I am trying to calculate the 'count' column in pBI but am struggling. I need to count the unique number of countries each customer is assigned to, for example John has 4, peter has 1 (Italy).
| Order Number | Customer | Country | Count |
| 1a | John | UK | 4 |
| 2a | David | Mexico | 3 |
| 3a | Peter | Italy | 1 |
| 1b | John | Germany | 4 |
| 2b | David | France | 3 |
| 3b | Peter | Italy | 1 |
| 1c | John | UK | 4 |
| 2c | David | Egypt | 3 |
| 3c | Peter | Italy | 1 |
| 4a | John | Poland | 4 |
Solved! Go to Solution.
@Sammy22 , Try using below mentioned DAX measure
Count = CALCULATE(DISTINCTCOUNT('Table'[Country]), ALLEXCEPT('Table', 'Table'[Customer]))
Proud to be a Super User! |
|
@Sammy22 , Try using below mentioned DAX measure
Count = CALCULATE(DISTINCTCOUNT('Table'[Country]), ALLEXCEPT('Table', 'Table'[Customer]))
Proud to be a Super User! |
|
Thank you! What if i want a date filter too with a date after 2022-01-02? @bhanu_gautam ?
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 8 | |
| 7 | |
| 6 | |
| 5 | |
| 5 |
| User | Count |
|---|---|
| 24 | |
| 11 | |
| 9 | |
| 9 | |
| 8 |