By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,830 Members | 682 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,830 IT Pros & Developers. It's quick & easy.

Calculate Years

P: n/a
Hi All
Being a Newbie and tried very hard to get my Database (Access) to calculate
the age of a person, in years, from the Date of Birth.

The Fields are:
DateofBirth minus Today's Date =Age, in years, of person.

Any help will be much appreciated.
Did post before but I think it got lost, sorry.
Many thanks
P...
Nov 12 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
You could try;

DateDiff("yyyy", Date_Of_Birth, Now)

BUT; there is a catch.... If you have the Date_Of_Birth as 01-Jan-2000 and
31-Dec-2000, they will both give you 3 years.... So you may have to a
comparison of the date and month as well, to figure out if you need to
subtract a year....

"Alan Mews" <al*******@btinternet.com> wrote in message
news:bn**********@titan.btinternet.com...
Hi All
Being a Newbie and tried very hard to get my Database (Access) to calculate the age of a person, in years, from the Date of Birth.

The Fields are:
DateofBirth minus Today's Date =Age, in years, of person.

Any help will be much appreciated.
Did post before but I think it got lost, sorry.
Many thanks
P...

Nov 12 '05 #2

P: n/a
> Being a Newbie and tried very hard to get my Database (Access) to calculate
the age of a person, in years, from the Date of Birth.

The Fields are:
DateofBirth minus Today's Date =Age, in years, of person.


See:

Age() Function
http://members.iinet.net.au/~allenbrowne/func-08.html

--
Bruce M. Thompson, Microsoft Access MVP
bt******@mvps.org (See the Access FAQ at http://www.mvps.org/access)
NO Email Please. Keep all communications

within the newsgroups so that all might benefit.<<
Nov 12 '05 #3

P: n/a
Many Thanks for all your help.

A....
"Alan Mews" <al*******@btinternet.com> wrote in message
news:bn**********@titan.btinternet.com...
Hi All
Being a Newbie and tried very hard to get my Database (Access) to calculate the age of a person, in years, from the Date of Birth.

The Fields are:
DateofBirth minus Today's Date =Age, in years, of person.

Any help will be much appreciated.
Did post before but I think it got lost, sorry.
Many thanks
P...

Nov 12 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.