Forum Discussion

PBInewbie17's avatar
PBInewbie17
Helper I
4 years ago
Solved

Processing Status Based on Multiple Dates

I want to add a calculated column called Processing Status (column in blue is desired result). Every staff member has 30 days to process a project, but if the project is missing relevant information, the assigned staff can suspend processing (i.e., put it on hold) until further information is received. Once the required data is received, staff can resume processing (Date Processing Resumed) and perform their review.

 

If a project has all required information and doesn’t need to be suspended, then total days in processing is the difference between the Date Completed and Date Assigned. If a project must be suspended, then total processing days equals [(Date Processing Suspended – Date Assigned) + (Date Completed – Date Processing Resumed)].

 

Here are the 5 statuses I need to calculate:

 

  • Incomplete = Missing data in system (see yellow highlighted fields). Indicates staff forgot to input data in system
  • On Time = Project complete and within 30-day timeframe
  • Missed Deadline = Project complete but past 30-day timeframe
  • In Processing = Project incomplete but within 30-day timeframe
  • Overdue = Project incomplete and past 30-day timeframe

Thank you for your assistance.

  • Anonymous's avatar
    Anonymous
    4 years ago

    Hi PBInewbie17 ,

    I have created a simple sample, please refer to it to see if it helps you.

    Create a measure.

    Measure =
    IF (
        MAX ( 'Table'[days in processing] ) > 30
            && MAX ( 'Table'[date completed] ) = BLANK (),
        "Overdue",
        IF (
            MAX ( 'Table'[days in processing] ) > 30
                && MAX ( 'Table'[date completed] ) <> BLANK (),
            "Missed deading",
            IF (
                MAX ( 'Table'[date completed] ) = BLANK ()
                    && MAX ( 'Table'[days in processing] ) <= 30
                    && MAX ( 'Table'[date due] ) >= TODAY (),
                "In progressing",
                IF (
                    MAX ( 'Table'[days in processing] ) <= 30
                        && MAX ( 'Table'[decision ] ) <> BLANK ()
                        && MAX ( 'Table'[date completed] ) <> BLANK ()
                        && MAX ( 'Table'[date processing resumed] ) = BLANK (),
                    "On time",
                    "Incomplete"
                )
            )
        )
    )
    

    If I have misunderstood your meaning, please provide more details with your desired output.

     

    Best Regards

    Community Support Team _ Polly

     

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

3 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi PBInewbie17 ,

    I have created a simple sample, please refer to it to see if it helps you.

    Create a measure.

    Measure =
    IF (
        MAX ( 'Table'[days in processing] ) > 30
            && MAX ( 'Table'[date completed] ) = BLANK (),
        "Overdue",
        IF (
            MAX ( 'Table'[days in processing] ) > 30
                && MAX ( 'Table'[date completed] ) <> BLANK (),
            "Missed deading",
            IF (
                MAX ( 'Table'[date completed] ) = BLANK ()
                    && MAX ( 'Table'[days in processing] ) <= 30
                    && MAX ( 'Table'[date due] ) >= TODAY (),
                "In progressing",
                IF (
                    MAX ( 'Table'[days in processing] ) <= 30
                        && MAX ( 'Table'[decision ] ) <> BLANK ()
                        && MAX ( 'Table'[date completed] ) <> BLANK ()
                        && MAX ( 'Table'[date processing resumed] ) = BLANK (),
                    "On time",
                    "Incomplete"
                )
            )
        )
    )
    

    If I have misunderstood your meaning, please provide more details with your desired output.

     

    Best Regards

    Community Support Team _ Polly

     

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

  • Please provide sanitized sample data that fully covers your issue. I can only help you with meaningful sample data.
    Please paste the data into a table in your post or use one of the file services like OneDrive or Google Drive.
    https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216

    Please show the expected outcome based on the sample data you provided. Screenshots of the expected outcome are ok.

    https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523