Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
script :load TX_DATE&WEEKDAY as tx_date,TOTAL_D,WEIGHT_D Resident TableName;
type of TX_DATE is date while type of WEEKDAY is string.
i expect the reslut of script like "2018/06/01Monday" but the reslut like "43213Monday".
why?
Try this
script:
LOAD Date(TX_DATE, 'YYYY/MM/DD') & WEEKDAY as tx_date,
TOTAL_D,
WEIGHT_D
Resident TableName;
Try this
script:
LOAD Date(TX_DATE, 'YYYY/MM/DD') & WEEKDAY as tx_date,
TOTAL_D,
WEIGHT_D
Resident TableName;
Hi Bill,
If you have date in your data, you don't need to concat dayname. You can simply change your date pattern.
LOAD Date(TX_DATE, 'YYYY/MM/DD WWWW') as tx_date,
TOTAL_D,
WEIGHT_D
Resident TableName;
'WWWW' in the formet patterns for showing the long name of weekday.
Example:
date(date#('2018/06/01','YYYY/MM/DD'),'YYYY/MM/DD WWWW')
Hope it helps..
Hi bill,
in cases where & is used, it is interesting to use this syntax by separating the two fields
LOAD Date(TX_DATE,'YYYY/MM/DD') &' - '& WEEKDAY as tx_date
returns : 2018/06/01 - Monday
thks!
thks!
thks too!
Please mark the correct answer as correct to finish off this thread