This is best Fabric, Power BI, SQL and AI community event. How do we know? The last event sold out! Save €200 with code FABCMTY200.
Register nowA new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.
Hello, I have a data set like this. I am trying to get a distinct count of the medication per MRN. The medication may repeat for the MRN but I would only like to count it once.
MRN Medication
0001 Drug A
0001 Drug A
0001 Drug B
0002 Drug C
0002 Drug A
0003 Drug B
0003 Drug B
I need the data to look like this
Drug A - 2
Drug B - 2
Drug C -1
Solved! Go to Solution.
Hi @warnera ,
Apart from Solution mentioned abovem you can try
Regards,
Harsh Nathani
Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)
a normal table can visualize the data as it is, should you not need the count in other calculations. Add a table to the canvas drop the Medicine column in it first and then add th distinct count of the MRN. rename the Count of MRN to MRN. a quick ways if all you want is the visualization.
Hi @warnera ,
Apart from Solution mentioned abovem you can try
Regards,
Harsh Nathani
Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)
Check out the May 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 27 | |
| 27 | |
| 25 | |
| 19 | |
| 14 |
| User | Count |
|---|---|
| 56 | |
| 48 | |
| 37 | |
| 21 | |
| 20 |