Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Determining age based on dob
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00592860
Message ID:
00592863
Views:
22
Are you sure your dob field is truly a date field? It seems that you should have gotten the number of days since the dob with that command (not what you were after, but better than an error).

Do this
MyDOB ={^1963-08-30}
? (DATE() - MyDOB) / 364.25

That should give you what you want.

JR


>How can I create an expression in expression builder to get a age of person based on their date of birth. For example:
>
>Dob          Age
>10/25/44     53.4
>
>
>I tried the expression (date()-person.dob) but it gave me an error as Ambigious date/datetime contstant. Is it even possible to find number of years and months in expression
>
>
>Thanks
>Nick Patel
CLARC Services, Inc.
3500 Tamiami Trail
Port Charlotte, FL 33952
www.clarc.com
(941) 743-0108
(800) 246-5488
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform