Skip to main content
Solved

Adding an extra day to datediff

  • April 28, 2021
  • 2 replies
  • 23 views

Forum|alt.badge.img+6

I’m running a datediff formula but it’s not displaying the result I’m expecting. I would like the output to include the day itself.

In other words if I’ve got a date range from 28 April to 30 April, for our purposes this is a 3 day event. DateDiff gives 2 days though.

DATETIME_DIFF
({Date ended},{Date started},
‘days’)&" days"

Any thoughts?

Best answer by kuovonne

You can add 1 to the difference

(DATETIME_DIFF(
  {Date ended},
  {Date started},
  ‘days’
) + 1)
&" days"

2 replies

kuovonne
Forum|alt.badge.img+29
  • Brainy
  • Answer
  • April 28, 2021

You can add 1 to the difference

(DATETIME_DIFF(
  {Date ended},
  {Date started},
  ‘days’
) + 1)
&" days"

Forum|alt.badge.img+6
  • Author
  • Known Participant
  • April 28, 2021

Utter brilliance! Thank you so much.