I have nodes with person label where i am storing their date of births too. For e.g.:
Person
{
name: Tim
D.O.B: 01/23/1990
}
Now I need to calculate his age as of current date and time ( i.e. either 27 years or 27 years, 10 months, 18 days ). So, could anyone let me know how could I perform it?
P.S.: I tried the following but seems to be missing something here :
WITH apoc.date.parse('01/23/1990', 'y', 'MM/dd/yyyy') AS startDate,
apoc.date.format(timestamp(),'y','MM/dd/yyyy') as endDate,
apoc.date.parse(endDate,'y','MM/dd/yyyy') as ed
RETURN ed - 4