Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Age from two fields, birthdate and deathdate

Status
Not open for further replies.

cimoli

Technical User
Jul 30, 2010
207
US
I am looking to add a calculated field into my Access 2003 query. I need to calculate a person age based on a death and birthdate. I would want just a simple rounded age EG age 86 or age 22. Not any decimals.

Is this possible?

Thanks for your help. I am doing this for my family genealogy report for the reunion.
 
Yes, this is possible. . .

How are the columns (bdate, ddate) defined?
 


Try:
Code:
[blue]= DateDiff("yyyy", birthdate, death) + Int(Format(death, "mmdd") < Format(birthdate, "mmdd"))[/blue]
[blue]Your Thoughts? . . .[/blue]

See Ya! . . . . . .

Be sure to see faq219-2884 [blue]Worthy Reading![/blue] [thumbsup2]
Also faq181-2886 [blue]Worthy Reading![/blue] [thumbsup2]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top