Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

Exact Age

Hello,

I'm trying to calculate the age of a personn at a date X. I have two columns, one is his birthday date and the other a date X . I would like to know the exact age of the personn at this day. For exemple if it's birthday is the 10/05/2018 and the X date is 11/05/2021, I would like to have 3. But if my X date is 09/05/2021 I would like to have 2.

I tried a datediff but after it gives me a number of day between those two dates and I don't know how to convert it to have the exact year cause of leap years...

if someone have a solution it would be very usefull.

Thank you

Have a nice day

Best regards

  • Anonymous 

    Add the Age column as follows:

    AGE = 
    INT(
        DIVIDE(
            [DATE X]-[DOB],
            365.25
        )
    )

     

2 Replies

  • Anonymous 

    Add the Age column as follows:

    AGE = 
    INT(
        DIVIDE(
            [DATE X]-[DOB],
            365.25
        )
    )

     

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thanks!