Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
| Date | Branch ID | Account Number |
| 9/29/2021 | 1525 | A |
| 10/3/2021 | 1525 | A |
| 9/30/2021 | 1525 | B |
| 9/28/2021 | 1525 | C |
10/1/2021 | 2010 | D |
10/2/2021 | 2010 | E |
9/9/2021 | 3009 | X |
9/11/2021 | 3009 | X |
This has been evading me all day. I have a table that looks like the one above, and I want to create a measure that gives me the distinct count of account numbers for the branch (which I just labelled as letters here). Essentially, I want to group by Branch ID and count the distinct values within that group using DAX. The output of the measure should take the values in the table below (but I don't want an actual table, I just want to have the measure give me the numbers in the output when I am looking at a specific branch).
| Branch ID | Output |
| 1525 | 3 |
| 2010 | 2 |
| 3009 | 1 |
I have been struggling with this all day and am looking forward to getting an answer on this.
Where do you want to use your measure if not in "an actual table"? What does the final result you're trying to get to look like?
Hi @Anonymous
Not sure i've fully understood what you want but a measure to count the number of account numbers would give this result.
Accounts count = DISTINCTCOUNT('Table'[Account Number])
What do you mean you don't want to output table? You can create that summary table as a variable in a measure, but you will then need to create some scaler value (sum of distinct counts, concatenation of the rows as text, etc.). What is your final desired output?
Pat
To learn more about Power BI, follow me on Twitter or subscribe on YouTube.
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 11 | |
| 9 | |
| 9 | |
| 5 | |
| 4 |
| User | Count |
|---|---|
| 27 | |
| 22 | |
| 20 | |
| 17 | |
| 12 |