Forum Discussion

janegrnisppl's avatar
janegrnisppl
New Member
3 years ago
Solved

Help with Count with Filters

Hello! I have been reading other solutions for filtering in count measures but so far no luck with mine. Here is my code for a measure:   Total active facilities = CALCULATE(DISTINCTCOUNT('FFAFacil...
  • v-jianboli-msft's avatar
    3 years ago

    Hi janegrnisppl ,

     

    Where do you want to apply this measure to? This measure may be affected by the context.

    Based on your description, I have created a simple sample:

     

    Please try something like:

    Total active facilities = CALCULATE(DISTINCTCOUNT('FFAFacilities'[FACILITY_ID]),FILTER(ALL('FFAFacilities'),'FFAFacilities'[CURRENT_STATUS]="01"))
    

    Final output:

     

    Best Regards,

    Jianbo Li

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.