Forum Discussion

JamesBurke's avatar
JamesBurke
Helper III
1 year ago
Solved

Placeholder error

Hi All ,    I'm looking for a measure to count the amount of buildings that exceed a threshold of one so i can count how mnay meters were active yesterday.    Online Buildings = CALCULATE(DISTIN...
  • SamWiseOwl's avatar
    1 year ago

    Hi JamesBurke 

     

    Two methods you coud try, one filtering the data and the other using an iterator function.

     

    Online Buildings Filter=
    Calculate(

    DISTINCTCOUNT(FactUWP[Grouped])

    Filter(FactUWP, [Total Consumption Todays Usages] > 1)
    )

     

    Countx values =
    SUMX(
    Values( FactUWP[Grouped] )

    , if([Total Consumption Todays Usages] > 1 ,1,0)

    )

     

    The error is because you aren't saying what you want to do with the IF statement.