I want to create another column using the filter step on the IDE. How do I concatenate foreign characters and fields with different data types into one field.
Fields to concatenate is date field, special character (/), string and integer fields
I want to create another column using the filter step on the IDE. How do I concatenate foreign characters and fields with different data types into one field.
Fields to concatenate is date field, special character (/), string and integer fields
Best answer by ivan.kozlov
Hi Gloria,
You can use the tostring() function to convert data to string but to make this work you also need to specify the format of the data.
For example toString(date_col, 'yyyy-MM-dd')
to get 2023-05-30
date. You’ll need to provide the right date format.
Here’s a link to ONE Expression documentation:
https://docs.ataccama.com/one/latest/common-actions/one-expressions.html
So the whole expression can look like this:
toString(date_column_name, “yyyy-MM-dd|”) + toString(integer_column_name) + “/” + string_column_name
Hope this helps,
Ivan
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.