cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Regular Visitor

Filter in DISTINCTCOUNT question

New to the forum.

Snippet of db below.

 

Using Powerbi I would like to figure out how many staff ate at the restaurant. But I only want them to be counted if they ate at the restaurant more than 5 times during the month. (There are 100's of staff member so DISTINCTCOUNT would need to be part of the measure) 

 

Any help appreciated

 

User_IDMealMonth
Joe SoapMain 1October
Joe SoapMain 1October
Joe SoapMain 1October
Joe SoapMain 4October
Joe SoapMain 5October
Cathy BlackMain 1October
Cathy BlackMain 1October
Cathy BlackMain 2October
Cathy BlackMain 3October
Cathy BlackMain 4October
Stewart LittleMain 5October
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Memorable Member
Memorable Member

Re: Filter in DISTINCTCOUNT question

@jacosmit

 

Create a new measure using the following formula

 

Measure = DISTINCTCOUNT(Table[Meal])

Then create a table and add UserID, Month as Dimensions and the measure.

 

See workspace on this link

 

Also you can use the filter pane to filter those who ate more than 5 times

 

image.png

View solution in original post

1 REPLY 1
Highlighted
Memorable Member
Memorable Member

Re: Filter in DISTINCTCOUNT question

@jacosmit

 

Create a new measure using the following formula

 

Measure = DISTINCTCOUNT(Table[Meal])

Then create a table and add UserID, Month as Dimensions and the measure.

 

See workspace on this link

 

Also you can use the filter pane to filter those who ate more than 5 times

 

image.png

View solution in original post

Helpful resources

Announcements
August 2020 Community Challenge: Can You Solve These?

August 2020 Community Challenge: Can You Solve These?

We're excited to announce our first cross-community 'Can You Solve These?' challenge!

Super Users of the Quarter - Q2 2020

Super Users of the Quarter - Q2 2020

Who are our Super User Superstars? Who made it to the top of the leaderboards? Get the answers!

Community Blog

Community Blog

Visit our Community Blog for articles, guides, and information created by fellow community members.

Community Summit Australia – Join Online!

Community Summit Australia – Join Online!

Be a part of the leading Microsoft Business Applications digital event, curated for the APAC community.

Top Solution Authors