Help

The Community will be temporarily unavailable starting on Friday February 28. We’ll be back as soon as we can! To learn more, check out our Announcements blog post.

Calculate elapsed time (to the minute) including days

Topic Labels: Dates & Timezones Formulas
1453 2
cancel
Showing results for 
Search instead for 
Did you mean: 
Jean_Thoensen
6 - Interface Innovator
6 - Interface Innovator

I'm building an issue tracker leading up to a one-day event. Issues are reported, and then I need to track how long the issue has been open. Most issues are closed in a few minutes, but others may linger for hours, or even days.

I can calculate the number of minutes since the issue was opened, but how do I convert that to a duration-like result that includes days? Sort of like a DD:HH:mm format.

This is how I calculate the elapsed minutes:

 

 
DATETIME_DIFF({Resolution Time}, {Call Time}, 'minutes') * 60
2 Replies 2
kuovonne
18 - Pluto
18 - Pluto

If you use 'seconds' as your units in DATETIVE_DIFF(), you can format the result as a duration. However, the duration format will only display in HH:mm format. It will not display days. If you want to display with days, you will need to use a formula that does the unit conversions manually. I might have written one a long time ago, but I cannot find it, and it would have been many lines with lots of arithmetic.

I'll try that, @kuovonne! I can probably make the formula display "n days" if the duration hour is >= 24. Thanks.