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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
chandishd
Frequent Visitor

Distinct count on the date based on the grouping Key and categorize it - DAX

Hi All, How do i achieve as menitoned in the below snip.

  1. How do i write a measure for below one
  2. I would be using this measure(RESULT2) to bar chart which tells the count(ID) based on the category.
  3. And if I have a slicer to the date, it should work accdly.

 

Any help on this is much appreciated.

 

Capture11.JPG

--

Regards

3 ACCEPTED SOLUTIONS
v-danhe-msft
Microsoft Employee
Microsoft Employee

Hi @chandishd,

Based on my test, you can refer to below steps:

1.I have entered some sample data to test for your problem like the picture below.

1.PNG

2.

2.Create a measure and a calculated column.

Measure = COUNT(Sheet1[ID])

Type = IF([Measure]=1,"Single","Many")

3.Create two Table visual and a Slicer visual and add the related fields. Now you can see the result.

2.PNG3.PNG

You can also download the PBIX file to have a view.

https://www.dropbox.com/s/cugktmidockb19y/Distinct%20count%20on%20the%20date%20based%20on%20the%20gr...

 

Regards,

Daniel He

Community Support Team _ Daniel He
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Hi @chandishd,

could you please tell me if your problem has been solved? If it is, could you please mark the helpful replies as Answered?

 

Regards,
Daniel He

Community Support Team _ Daniel He
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-danhe-msft
Microsoft Employee
Microsoft Employee

Hi @chandishd,

Based on my test, you can refer to below steps:

1.I have entered some sample data to test for your problem like the picture below.

1.PNG

2.

2.Create a measure and a calculated column.

Measure = COUNT(Sheet1[ID])

Type = IF([Measure]=1,"Single","Many")

3.Create two Table visual and a Slicer visual and add the related fields. Now you can see the result.

2.PNG3.PNG

You can also download the PBIX file to have a view.

https://www.dropbox.com/s/cugktmidockb19y/Distinct%20count%20on%20the%20date%20based%20on%20the%20gr...

 

Regards,

Daniel He

Community Support Team _ Daniel He
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thank you v-danhe-msft 

Hi @chandishd,

could you please tell me if your problem has been solved? If it is, could you please mark the helpful replies as Answered?

 

Regards,
Daniel He

Community Support Team _ Daniel He
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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.