cillion

Calculate age when born

Discussion created by cillion on Aug 2, 2016
Latest reply on Aug 2, 2016 by taylorsharpe

Hi.

I have a previous used database that set the age as the 2 last numbers in the year they where born.

 

On new records now, I have the born selector return full date format like this: 29.06.1990.

 

How could I make a second field that will calculate how old a person is with these two ways of setting the born date?

 

Now my yearsOld field have a calculation like this:

Year ( Get ( CurrentDate ) ) - Year ( GetAsDate ( Born ) ) - If ( Get ( CurrentDate ) < Date ( Month ( GetAsDate ( Born ) ) ; Day ( GetAsDate ( Born) ) ; Year ( Get ( CurrentDate ) ) ); 1 ; 0 )

 

NB! the born field is a text field

Outcomes