Forum Discussion
kvandehy
9 years agoNew Member
DAX | Average If Value > 0
Please help - I am very new to DAX functions and have not been able to find a solution to my problem. I have a column of hours worked for each employee and I want to create a measure to calculate...
- Anonymous9 years ago
If you wanted to literally average the values, it would be
= CALCULATE ( AVERAGE(Employee[Hours]), Employee[Hours] <> 0 )
Though, I can totally imagine other interpretations of "average" :)
kvandehy
9 years agoNew Member
No, unfortunately the employees with no hours have "0.00" in the Charge Hours column so it is not blank. I would like to be able to find average hours for all employees for the month by service unit, department and total company but the 0's are throwing off the count of employees.
Anonymous
9 years agoNot applicable
If you wanted to literally average the values, it would be
= CALCULATE ( AVERAGE(Employee[Hours]), Employee[Hours] <> 0 )
Though, I can totally imagine other interpretations of "average" :)