Expand my Community achievements bar.

Announcing the launch of new sub-community for Campaign Web UI to cater specifically to the needs of Campaign Web UI users!
SOLVED

Conversion of date and time format yyyy-mm-ddThh:mm:ss:sss to dd/mm/yyyy hh:mm:ss

Avatar

Level 4

Hi team,

We have a requirement of importing data into schema with the help of workflow where the data is coming in .csv file format.

For one of the date field, we are receiving the format as "yyyy-mm-ddThh:mm:ss+0100". But we have to convert the time and date into iso format like "dd/mm/yyyy hh:mm:ss" and need to import into schema.

Can anyone please help in conversion of above date and time formats.

 

Thanks,

Raviteja.

1 Accepted Solution

Avatar

Correct answer by
Level 6

Hi, the problem is not really as converting date format itself but more if the incoming format is understood by AC as a regular date time:
formatDate function is only for string conversion format... But, whatever the date format is, as long as AC understand it as a date, you can save it in a dateTime attribute schema without any issue.
The way it will be rendered by default in the nl console client depends of the DB preferences.
Once, in your schema's date time attribute, you can render the date as you want by converting it to a string with formatDate 

View solution in original post

5 Replies

Avatar

Correct answer by
Level 6

Hi, the problem is not really as converting date format itself but more if the incoming format is understood by AC as a regular date time:
formatDate function is only for string conversion format... But, whatever the date format is, as long as AC understand it as a date, you can save it in a dateTime attribute schema without any issue.
The way it will be rendered by default in the nl console client depends of the DB preferences.
Once, in your schema's date time attribute, you can render the date as you want by converting it to a string with formatDate 

Avatar

Community Advisor

Hi @ravitejagundu ,

I hope the following mat help.

1.import the the field a string in data loading workflow

2. in an enrichment activity add a new column of datetime type

3. Write an expression to convert the string to the new datetime field.

 

Cheers,

Deb

Avatar

Level 1

Hi Deb,

 

Can you please share the expression used in the enrichment activity for the date conversion?

Avatar

Administrator

Hi @ravitejagundu,

Were you able to resolve this query with the help of any of the given solutions or do you still need more help here? Do let us know.
Thanks!



Sukrity Wadhwa