Skip to main content
Question

Overdue Duration Formula most be positive # of Days

  • October 16, 2023
  • 0 replies
  • 178 views

Forum|alt.badge.img+8

Hey QuickBase Community, I have a Duration Formula field that is looking at the difference between "today()" and the finish date of a given task record. the field is designed to tell me if the record is past due based on the finish date.

the issue is it gives me a negative number of days for the task that are still yet to be completed aka not overdue yet.

can you help me format this duration formula so that it only shows a positive # of days when the task is officially overdue?

If([Status]="Overdue",Today() - [Finish Date],If([Status]="Not Started",Today() - [Finish Date],If([Status]="In Process",Today() - [Finish Date],null)))

 



------------------------------
Jack Woods | Low Code 4 Lyfe
------------------------------

This topic has been closed for replies.

Forum|alt.badge.img+9
  • Registered
  • October 16, 2023

You can just check first to see if Finish date is in the future and nullify it. You also don't have to nest each new if as a new statement to make it more readable, you can just do like so: 

If(

[Finish Date]>=Today(), null,

[Status]="Overdue",Today() - [Finish Date],
Status]="Not Started",Today() - [Finish Date],

[Status]="In Process",Today() - [Finish Date],

null)



------------------------------
Chayce Duncan
------------------------------