Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hello,
I have any interesting count I'm trying to run and I'm having some issues trying to get the right answer. To lay the ground work and what I'm looking to accomplish, here is what I have. I have the following columns Record Id, Workflow Stage, Workflow Tracking Type (action executed value), Workflow Date Modified (tracks when a workflows action was executed), Date Created, and Investigation due date. The workflow stages have the following values; Draft, Verification, Investigation, Approval, and NULL for completed. When a workflow stage is transitioned to the next workflow stage, we capture the date this happens (Workflow Date Modified). Unfortunatley we don't have a column to capture when a workflow stage is due, otherwise I wouldn't be having an issue counting what I'm trying to count.
Here is what I'm trying to count, I want to count any record that was overdue and then completed. The due dates for each workflow stage are as follows.
Draft = 1 day since the incident was created and saved.
Verification = 1 day plus the date the workflow was moved into this stage. Essentially 1 day plus the "Draft" workflow stages "Workflow Date Modified" date.
Investigation = This is a value in the Investigation due date column, easy enough to calculate.
Approval = 5 days plus the date the workflow was moved into this stage. 5 days plus the Investigation workflow stages "Workflow Date Modified" date.
Each of these values listed above are all on different rows, but we have a record id number to tie them all together.
Here is an example dataset:
Record ID | Workflow Stage | Workflow Tracking Type | Workflow Date Modified | Date Created | Investigation Due Date |
12345 | Draft | Action Excuted | 1/1/2023 | 1/1/2023 | 1/6/2023 |
12345 | Verification | Action Executed | 1/1/2023 | 1/1/2023 | 1/6/2023 |
12345 | Investigation | Action Executed | 3/29/2023 | 1/1/2023 | 1/6/2023 |
12345 | Approval | Action Executed | 3/30/2023 | 1/1/2023 | 1/6/2023 |
I'm trying to figure out how to calculate if one of these workflow stages is overdue, but has been closed out, then count that workflow stage. Eventually ending up with a count of "rows" where the Workflow stage was completed past it's theoretical due date. In the above scenario only the Investigation stage would be considered overdue.
Thank You,
Trevor Bensen
Solved! Go to Solution.
you can try to createa a step column
Proud to be a Super User!
Hi @TBensen
Thanks for reaching out to the Microsoft fabric community forum.
I would also take a moment to thank @GeraldGEmerick and @ryan_mayu , for actively participating in the community forum and for the solutions you’ve been sharing in the community forum. Your contributions make a real difference.
I hope the above details help you fix the issue. If you still have any questions or need more help, feel free to reach out. We’re always here to support you
Best Regards,
Community Support Team
you can try to createa a step column
Proud to be a Super User!
Hello,
I think this might work! One thing I am seeing is that it appears to only be showing an Investigation or Approval workflow stage as being overdue. Is there a way to apply this to the Verification stage which has a due date of +1 after the Draft stage has been completed?
Would I add another If statement into the Return formula to to look at "Step=2" and WorkflowDate Modified > _draft+2?
Thanks,
Trevor Bensen
yes , the your coding logic is correct. And you can add one more if condition in the DAX.
Proud to be a Super User!
Excellent, thank you for your help!
you are welcome
Proud to be a Super User!
Hello,
Sorry, I should have included that in the original post. I'll go back and add it. I want to count every instance where a Workflow stage was completed past its theoretical due date. In the example above, the Investigatoin workflow stage is past its due date, so that would be counted as 1. The Approval workflow stage wouldn't be past due as it had been completed within 1 day of moving into the approval workflow stage.
Thanks,
Trevor Bensen
@TBensen What is the expected output given the input data? You will likely want to unpivot your date columns but tough to know for certain as it is difficult to follow what you are trying to accomplish.
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.