#datediff('yyyy',CREATEDATE(yyyy,mm,dd),now())# will give you whole years,
interesting question about days though, as how does it handle leap years
etc?
-----Original Message-----
From: Lovelock, Richard J [mailto:[EMAIL PROTECTED]
Sent: 01 October 2003 15:23
To: 'cflist'
Subject: [ cf-dev ] Age calculation
hiya...
If i have someones DOB in the database - how can i find out their age in
years?
presume I can do some date subtraction using #dob# and #now()# but not sure
how to do this syntactically and return an integer year value (or even
integer year and days!! e.g 26 years 37 days old)
_______________________________________________________<?xml:namespace
prefix = o ns = "urn:schemas-microsoft-com:office:office" />
* Regards,
Richard Lovelock
Westminster City Council - Web Support
Cap Gemini Ernst & Young
Southbank
95 Wandsworth Road
London
SW8 2HG
( 0870 906 7482
_______________________________________________________
****************************************************************************
****************
" This message contains information that may be privileged or confidential
and
is the property of the Cap Gemini Ernst & Young Group. It is intended only
for
the person to whom it is addressed. If you are not the intended recipient,
you
are not authorized to read, print, retain, copy, disseminate, distribute, or
use
this message or any part thereof. If you receive this message in error,
please
notify the sender immediately and delete all copies of this message ".
****************************************************************************
****************
DISCLAIMER: This e-mail is confidential and may also be legally privileged.
If you are not the intended recipient, use of the information contained in
this e-mail (including disclosure, copying or distribution) is prohibited
and may be unlawful. Please inform the sender and delete the message
immediately from your system. This e-mail is attributed to the sender and
may not necessarily reflect the views of the Patsystems Group and no member
of the Patsystems Group accepts any liability for any action taken in
reliance on the contents of this e-mail (other than where it has a legal or
regulatory obligation to do so) or for the consequences of any computer
viruses which may have been transmitted by this e-mail. The Patsystems Group
comprises Patsystems plc and its subsidiary group of companies.
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]