Forum Academy Marketplace Showcase Pricing Features

Calculate years, weeks, days from two dates

Hi all,

I need to calculate number of years, weeks and days from two dates. I am able to simply calculate the total number of days, but I can’t figure out how to narrow down from years to weeks to days. (for example 2 years, 25 weeks and 4 days).

Thanks!
Wouter

Hey there, you can take date 2 (the higher date) - date 1 :format as days then do maths.

For weeks / 7
For months / 30
For years / 365

Here an example:

Live: https://lolcomp.bubbleapps.io/version-test/time?debug_mode=true
Editor: https://bubble.io/page?type=page&name=time&id=lolcomp&tab=tabs-1

This topic was automatically closed after 70 days. New replies are no longer allowed.