Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello,
I'm still fairly new to using DAX in PowerBI. I was wondering how I can count number of rows based on a unique value.
So for instance:
Table 1
Class | Lang
------------------
1 | English
1 | English
1 | English
1 | Chinese
2 | Italian
3 | Arabic
3 | Arabic
3 | Chinese
What I was hoping for:
Resulting measure "Result"
Class | Language | Result
---------------------------------------
1 | English | 3
1 | Chinese | 1
2 | Italian | 1
3 | Arabic | 2
3 | Chinese | 1
How can I create the measure "Result" in DAX based on the example diagrams above?
Thanks
Solved! Go to Solution.
You don't need to create the measure "result" to do that, you only have to add "Lang" again to values pane and select "count" option fos this.
See the example:
@Anonymous ,
Or you can just use measure
Result = COUNT('Table'[Lang])
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Anonymous ,
Or you can just use measure
Result = COUNT('Table'[Lang])
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
You don't need to create the measure "result" to do that, you only have to add "Lang" again to values pane and select "count" option fos this.
See the example:
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
71 | |
70 | |
43 | |
31 | |
26 |
User | Count |
---|---|
89 | |
49 | |
44 | |
38 | |
37 |