DateTime Convertion Issue in DataTable

Hello Forum…

I’m trying to perform an operation where I convert all the DateTime values from a datatable column to a different format, but I kept getting the wrong result.
The context is basically that I’m receiving a whole range of text as input that I have to convert to a CSV file. The text is well separated by commas, and the columns that represent a date come in this format (dd-MM-yyyy). However, when I use the ‘Generate Data Table From Text’ activity and output the data table, all the values from those columns representing a Date are converted to the format (dd/mm/yyyy hh:mm:ss). Now, when I want to undo the default changes made by the activity by basically converting every date format again, I get the exact same format as output even though I did the opertation in each row as you can see in the first image. And as you can see iin the second iage the date format are the not desire ones.

I’ve been battling for a while now every time I want to convert data to a data table because it modifies these kinds of values.

Essentially, my question here is, why am I not able to convert the date-time values with this solution? How can I solve this?"


Hi,

Can you try to turn off AutoDetectTypes property of GenerateDataTable activity? Probably it’s converted to DateTime type by this feature.

image

Regards,

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.