Page 1 of 1

Logic for date of birth with age

Posted: January 2nd, 2018, 2:30 pm
by juan pablo
Dear team

They could help me with the following query.

I'm guiding myself on an example data entry Chapter5Exercises to be able to reuse its logic to detect the inconsistency between date of birth and age but when I apply it to my data entry I get the following error

ERROR: '' is a reserved word - use another name
ERROR: Single variable - can not have subscript (unexpected left parenthesis) near line 47 in FECHA_NC_DIA procedure

Re: Logic for date of birth with age

Posted: January 2nd, 2018, 3:50 pm
by khurshid.arshad
Dear;
Please use this code. I hope it works.
I think you have the maximum number of times is 1, you don't need curocc() in your code.

Code: Select all

Numeric calculateage=datediff(DATE_OFF_BIRTH,
							FECHA_ENCUESTA,"y"); 
Best.
a.

Re: Logic for date of birth with age

Posted: January 3rd, 2018, 11:04 am
by juan pablo
thank you very much dear khurshid.arshad

  his indication gave solution to my problem