on 09-11-2015 5:34 AM
hello,
i want to use cleansing package builder in information steward to clean my data, as follows:
i would like to convert day of 7 numbers to Date format (dd/mm/yyyy)
for example: convert value 2000001 become 01/01/2000.
i created custom cleansing packed named : Test_01092015.
then i publish and get data service and import file .atl
after that i created a data flow. then i choose Data transform to map input field
but i can not map output fields because : BLANK OPTION AND BLANK OUT PUT FIELDS?
TELL ME WHY?
please help me emergency !!!
No need to use a CP for date conversion. Use the built-in DS functions instead.
E.g.:
print(to_date(substr(to_char(2000001,'9999999'),2,4)||'0101','YYYYMMDD')+mod(2000001,1000)-1);
> 2000.01.01 00:00:00
print(to_date(substr(to_char(2015365,'9999999'),2,4)||'0101','YYYYMMDD')+mod(2015365,1000)-1);
> 2015.12.31 00:00:00
You can create a simple custom function with this logic with one parameter of type int and return type date.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.