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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
corange
Post Patron
Post Patron

Measure with a filter - IF

Hi everyone, 

 

I am after some help with one of my project. 

 

I have a company with three departments - Univeristy, Primary School and Secondary School and the company is located in two states. i report on different metrics and one of them is the average daily jobs per employee and per state. In the report, I offer user the posibility to see metrics by department using a slicer visual as a filter. For me to obtain the average daily job number, I simply drop Units in the field and select "average". 

 

Where I am stuck is that if an employee is working for University and does 1 to 3 jobs a day, it should be removed from the average. The results should always incorporate this rule not matter if I select the slicer visual to check on all Department or a specific Department: employee working for University doing less than or equal to 3 jobs a day, are not to be included in the average daily job number. For those same employees, we report on their earnings and average working hours daily and it is to be included even if it was only 1 job. Therefore I can't go to the source and filter all <=3 jobs a day as i still need some of the data against that employee. 

 

I have highlighted below what should be excluded from my average job number for the University Employee: 

Capture2.PNG

To obtain the following results: 

 

Capture3.PNG

 

Here a sample of my dataset: https://1drv.ms/u/s!AiS7XVNuQsBCc4RVVjGVoKHwa4Y?e=6AOLFP 

 

I really hope someone can assist as I dont know at all how I can solve this. 

 

Thank you. 

 

 

1 REPLY 1
amitchandak
Super User
Super User

@corange , Try measures like that

 

countX(filter(summarize(Table,Table[employee],"_1", sum(Table[unit])),[_1]<=3),[employee])


sumX(filter(summarize(Table,Table[employee],"_1", sum(Table[unit])),[_1]<=3),[_1])

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.