Forum Discussion

Marco_88's avatar
Marco_88
Helper I
2 years ago
Solved

Need help tracking activities (Filter, Count, Conditional formatting)

Hi everyone,  I have a table that tracks the activities of a hotel refurbishmnet. I have a series of rows corresponding to different activities, done or still to be done, for some rooms.  I would ...
  • Ritaf1983's avatar
    2 years ago

    Hi Marco_88 
    You can use 2 measures:
    1. 

    Complete rooms =
    VAR RoomStatusCounts = SUMMARIZE('database', 'database'[ROOM NUMBER], "StatusCount", DISTINCTCOUNT('database'[STATUS]))
    RETURN
    COUNTROWS(FILTER(RoomStatusCounts, [StatusCount] = 1 && CONTAINSSTRING(CONCATENATEX(FILTER('database', 'database'[STATUS] = "DONE"), 'database'[ROOM NUMBER], ", "), 'database'[ROOM NUMBER])))

    2. 

    Not_completed rooms = DISTINCTCOUNT(DATABASE[ROOM NUMBER])-[Complete rooms]

    PBIX is attached

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