Forum Discussion

PBINewbie920's avatar
PBINewbie920
Icon for Helper I rankHelper I
4 years ago
Solved

Create Column for "in progress"

Hi!  I have a table that has three fields: Date, ID & Type. I want to create a third column to determine which projects are still in progress (those projects that do not have type=billed)   For in...
  • Shishir22's avatar
    4 years ago

    Hello PBINewbie920 ,

     

    Please try below calculated column -

    In Progress =
    VAR _Count =
        CALCULATE (
            COUNT ( 'Table'[Project ID] ),
            FILTER (
                'Table',
                'Table'[Type] = "Billed"
                    && 'Table'[Project ID] = EARLIER ( 'Table'[Project ID] )
            )
        )
    RETURN
        IF (
            FIRSTNONBLANK ( 'Table'[Type], 0 ) = "Booked"
                && ISBLANK ( _Count ),
            "Yes",
            "No"
        )

     

    Please mark it as solution if it solves your issue. Kudos are also appreciated.