I created a chart report that shows our numbers of published & unpublished courses year over year. One thing I'd like to exclude is courses with 0 enrollments. These courses would never be published, so it skews the results.
I created a new column in my course_dim table called student_enrollment, then I wrote a DAX statement for that column:
student_enrollment = calculate(countrows(enrollment_dim),
filter(enrollment_dim, enrollment_dim[type] == "StudentEnrollment"
&& course_dim[id] == enrollment_dim[course_id]
&& enrollment_dim[workflow_state] <> "deleted"))
The courses with 0 enrollment are blank instead of showing a 0, which doesn't seem like it should be a problem.
When I add the student_enrollment column as a filter to my report, I select "Show items when the value is not blank", then click Apply filter, nothing changes. If I change it to "is blank", all the results disappear. Any ideas?