Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I Woud like to calculate the age of employees (from the current date). What load script should I use to create a new field Age?
[Employees off]:
Directory;
LOAD *,
DATE(DATE([Date of Birth], 'D-MM-YYY'), 'DD-MMM-YY') as Birthday,
FROM
Datasources\EmpOff.xls
(biff, embedded labels, table is Employee$);
Thank you in advance.
Kind Regards
Hi,
Work on the date functions for this that will help you and create the another table resident of the current, you can find the many post related to this will help you.
Regards
Anand
[Employees off]:
Load *,
Age(Today(), [Birthday]) as Age;
LOAD *,
DATE(DATE#([Date of Birth], 'D-MM-YYY'), 'DD-MMM-YY') as Birthday
FROM
Datasources\EmpOff.xls
(biff, embedded labels, table is Employee$);
You can also use
Interval( Today(), [Birthday], 'YY' ) as Diff
Regards
Anand
You can use
Age(today(),[Date of Birth])
The Function age() works fine.