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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

How to count value based on another count aggregate

Hi community,

This may seem like a stupid question but I am fairly new to PowerBI so I  require your aid.

I have a table with users, and their unique event_dates of logons.

I guess my task constists of two things:

1) First - the below table displays how many unique event dates I have for each individual (How many unique days I see atleast 1 login) -> which is basically count(event_date)

Capture.PNG

I need to have another table where I can aggregate the number of these emails by company, but with a specific filter with above certain days of unique days activity. So for example, in the picture above I have 5 emails, where the first one has logged in 20 different days. On a separate table I need to have the company and to be able to count emails that have logged atleast >10 times. Which should result in Company A, Email_Count : 1, since only user meets the criteria.

After this has been achieved, I want to have a dynamic filter where the user can put the treshold himself. So if he is not satisfied with >10 condition, let's say he makes it > 2 , this should return two emails in that company.

So in short, I need to count the event dates for each individual, then count the individuals that meet certain amount of count event dates, and then filter by the count of event_dates so it can be flexible.

Is that possible? Thanks!

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,

I created a sample pbix file(see the attachment), please check if that is what you want.

vyiruanmsft_0-1687156647624.png

Best Regards

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @Anonymous ,

I created a sample pbix file(see the attachment), please check if that is what you want.

vyiruanmsft_0-1687156647624.png

Best Regards

some_bih
Super User
Super User

Hi @Anonymous to create separate table with filter you want you should create calculated table  as example shown on link. In that newly created table you can filter your "counting" and created calculated columns as you wish. Hope this help

 https://learn.microsoft.com/en-us/power-bi/transform-model/desktop-calculated-tables 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!






Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.