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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
rwalsh200493
New Member

DAX distinct counts

Hi,

 

I am newish to Power Bi i am trying to find out how many operators have entered data each day.

 

i have removed alot of the noisey information but from the below i would like the column "Operator" to have the value 3 next to 03/01/2024 and only have one row for this and this logic flowing down.

 

I thought changing the "summarization" to "count(distinct" would complete this but it made no change.

 

i have also tried a "distinctcount" within the "sumarize" portion of the formular and this has not worked.

 

If someone can provide me with some advice as to how to complete this that would be great.

 

rwalsh200493_0-1708612565590.png

 

 

1 ACCEPTED SOLUTION
Greg_Deckler
Super User
Super User

@rwalsh200493 Try:

Table = 
  SUMMARIZE(
    'Table',
    'Table'[Date.1].[Date],
    "Operator",
    COUNTROWS(DISTINCT('Table'[Operator]))
  )


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Power BI Cookbook Third Edition (Color)

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

3 REPLIES 3
Greg_Deckler
Super User
Super User

@rwalsh200493 Try:

Table = 
  SUMMARIZE(
    'Table',
    'Table'[Date.1].[Date],
    "Operator",
    COUNTROWS(DISTINCT('Table'[Operator]))
  )


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Power BI Cookbook Third Edition (Color)

DAX is easy, CALCULATE makes DAX hard...

This solution was ideal thanks as i needed to complete this through DAX and not the power Query editor as i used DAX to create the table. I should have put that in the intial brief

Syk
Super User
Super User

Open your Power Query editor and select your date column > Group by

Syk_0-1708613380297.png

make sure you're grouping on your date then select "Count Distinct Rows" under operation

Syk_1-1708613445106.png

 

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.