6 Replies Latest reply: May 15, 2014 9:57 AM by Steve Caiels

# calculated field (calculate Age)

I have a field for DOB (MMDDYY). How can I create a calculated field in the model to give the age base on todays date?  :confused:

• ###### calculated field (calculate Age)

Part two. In the report I am using the date is shows up as 120335. When I change the format to date it shows as 12/3/2035. It does not do this for every line???? any suggestions????

• ###### calculated field (calculate Age)

Part three... the only time this year change occurs is for dates where the year is 1949 or less. Is this a Y2K conversion thing?

• ###### calculated field (calculate Age)

In Monarch under Options -&gt; Input... you can set the date range for 2 digit years.  The default is 1950 - 2049.  Which means any 2 digit year before 50 will be "translated" as the year 2000 (i.e. 120335 will be 12/03/2035).

• ###### calculated field (calculate Age)

Hi

Since you are probably using 2-digit dates before 1950, then you should make sure that your 2-digit date translation window is correct.

Go into Options | Input and change the value for "Date Range for Two Digit Years" to the right 100-Year window you need.

As regards finding the Age, then a formula like this will help, but is not exact.

int((Today()-BirthDate)/365.25)

• ###### calculated field (calculate Age)

I know this is an OLD post, but I found this formula to do this.

IF(MONTH(TODAY())&gt;MONTH(),YEAR(TODAY())-YEAR(),IF((MONTH(TODAY())=MONTH() .and. DAY(TODAY())&gt;=DAY()),YEAR(TODAY())-YEAR(),(YEAR(TODAY())-YEAR())-1))

• ###### calculated field (calculate Age)

Hi,

The following formula will give a correct age.

[font="courier"]if(

(month(dob)100)+day(dob)&lt;(month(date())100)+day(date()),

year(date())-year(dob),

year(date())-year(dob)-1)

)[/font][/quote]The condition multiplies the month by 100 and adds the day of the month to give a value that can be compared to todaus date to see if it has passed or not (ignoring the year)

Regards

Steve