Formula to count number of days between Date field and end date of Timeline field

Hi all! My team uses a template that includes both a Date column (for Deadline) and a Timeline column. These columns can sometimes get out of sync—say, a timeline shifts out a few days, but the deadline is not updated to match—making it tricky to understand when tasks are behind or not.

I’d like to add a formula that pulls the end date from the Timeline column and counts the number of days between that date and the Deadline. That way I can filter for any values not equal to 0 to focus on validation/cleanup.

The formula I’ve got: DAYS({Deadline}, {Timeline#end})

But that’s not quite right, and it seems to return the number of days between Timeline START and Deadline. For example, for an item with Deadline = 2/27 and Timeline = 2/24 - 2/27, it’s returning 3. Any ideas?

Hi there,

You’re very close — the issue is just the order of the arguments in the DAYS() function.

In monday, DAYS(date1, date2) calculates date1 minus date2. So when you write:

DAYS({Deadline}, {Timeline#end})

it’s effectively calculating Deadline minus Timeline end. If the timeline start is being interpreted instead, it’s usually because the end value isn’t being read the way you expect.

To compare the Timeline end date to the Deadline and return 0 when they match, try flipping the order:

DAYS({Timeline#end}, {Deadline})

For your example:

Timeline = 2/24–2/27

Deadline = 2/27

This should return 0, which makes it easy to filter for anything not equal to 0.

If you want to be extra safe and handle blanks, you could also use:

IF(AND({Deadline}, {Timeline}),
   DAYS({Timeline#end}, {Deadline}),
   ""
)

That way the formula only calculates when both fields are filled.

Once that’s in place, filtering for values not equal to 0 is a clean way to surface items that need validation.

If you’d like hands-on help or want us to walk through this live, you can book a 1:1 paid 60-minute strategy session with our team here:
Calendly

Hi @robin.hogan, you can use the formula suggested by Dr. Sachar.

Additionally, if you’re on the Pro or Enterprise plan, you can do this without a formula column or any manual updates by using a workflow.

Workflow structure:

  1. When column changes → Column: Timeline

  2. Set date → Column: Due Date (set it to the Timeline end date)

This way, whenever the Timeline changes, the Due Date automatically updates to match the end date. Hope this helps!