Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

This topic is 7062 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted (edited)

Hi all friends

does someone know if there are international rules for the birthday of a person born on february 29 ?

I think that if a baby was born on 02/29/2000, his birthdays were:

02/28/2001 firts year

02/28/2002 second year

02/28/2003 third year

02/29/2004 forth year ( on 02/28/2004 he was 3 years old)

If what I think is right (internatinal rule), the calc for the age in years format:




Year(theDate) - Year(birthday) - (theDate < Date(Month(birthday); Day(birthday); Year(theDate)))



is always good except in this case.

Edited by Guest
typo corrected
Posted

Anyway this code does the trick:




Let([

y1 =If ( Mod( Year ( birthday ) ; 4 ) = 0 ; 1 ; 0 );

y2 =If ( Mod ( Year ( theDate ) ; 4 ) = 0 ; 1 ; 0 );

d =  If(Day ( birthday ) = 29;1;0);

m = If( Month ( birthday ) = 2;1;0);

cd = If(y1 *y2   = 0 and  d * m = 1;Date ( Month ( birthday ) ; Day ( birthday ) - 1 ; Year ( birthday ) );birthday)

];

Year(birthday) - Year(cd) - (theDate < Date(Month(cd); Day(cd); Year(theDate)))

)



Posted

Just a tip, Daniele. All of your Let vars up to and including m are boolean statements in their own right. So you can use

y1 = not Mod( Year(birthday); 4 );

y2 = not Mod( Year(theDate); 4 );

d = Day(birthday) = 29;

m = Month(birthday) = 2;

Posted

Hi all friends

does someone know if there are international rules for the birthday of a person born on february 29 ?

I think that if a baby was born on 02/29/2000, his birthdays were:

02/28/2001 firts year

02/28/2002 second year

02/28/2003 third year

02/29/2004 forth year ( on 02/09/2004 he was 3 years old)

If what I think is right (internatinal rule), the calc for the age in years format:




Year(theDate) - Year(birthday) - (theDate < Date(Month(birthday); Day(birthday); Year(theDate)))



is always good except in this case.

I think the answer should be 3 Years, 11 Months, 11 Days

on Feb 9, 2004.

What answer are you looking for.

Lee

This topic is 7062 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.