Sheila has attended:
Access Intermediate course
Dates of Birth
We have got details of people's dates of birth but would like Access to tell us their ages automatically.
RE: Dates of Birth
Hi Sheila - apologies for the delay. I have a couple of suggestions for a calculated field in a query. Should have them online by end of today.
Kind regards,
Andrew
RE: Dates of Birth
Hi Shirley
Make a query based on the table containing the DOB field. Create a custom field in the query by adding the following to the field row:
Age: DateDiff("yyyy",[DOB],Now())+Int(Format(Now(),"mmdd")<Format([DOB],"mmdd"))
This uses the datediff function to work out the difference between your DOB field and today's date. You should find your query now has a new column called Age with the calculated value.
There are several ways of approaching this but this might just do the trick. Give it a try and see if the results work with your data.
Kind regards,
Andrew