Year(num(Today()))-Year(DoB_Loy) as Age --- to create age buckets
I need to create age buckets for my model, but i think the Field 'DoB_Loy' needs to be reformatted for my script above to work, or the script above needs to be reformatted.
DoB_Loy format: 'YYYYMMDD'
Today format: 'DD/MM/YYY'
This is the complete script I have for creating the Age Buckets:
AgeTransactions:
LOAD num#(CardNo) as CardNo, Year(num(Today()))-Year(DOB) as Age