Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello everyone,
I'm using talend open studio data integration and new to this tool.
I have a csv file that has timestamp column and i'm trying to convert this in the schema of the input delimted_file. and I get the below error.
Couldn't parse value for column 'Tx_Timestamp' in 'row1', value is '07-JUL-18 05.17.36.000 PM -05:00'. Details: java.lang.RuntimeException: Unparseable date: "07-JUL-18 05.17.36.000 PM -05:00"
I tried this various options like "dd-MMM-yy HH.ms.ss.SSS a Z" but nothing helped.
Please let me know.
Are you looking for the following output?
Regards,
Yes this is exactly the output I need . so I need to us this following below to convert it?
TalendDate.ParseDateinUTC ( )
and I won't be able to use this in the FileInput_Delimted . under edit schema? Correct?
I can use it in tmap in expression editor and use that as a separate column/variable?
Thanks!
Hi bro!
When I have to convert a TimeStamp field to a DateTime field, I like to create a routine in Talend for these purpose, and I'm going to show you how with a simple example where I've got a .csv input with a TimeStamp in milliseconds connected to tMap and the tMap output to a .csv output where I'm going to have two fields, the old timestamp and his correspondent DateTime.
-> This is the .CSV file input
Now I'm going to show you the talend routine to convert timestamp in milliseconds to datetime ("dd:mm:YY HH.mm.ss.SSS")
In the next step, you only have to aplpy the created routine in the tMap output option, expression builder!
Now just Run the job and woalah! \(^.^)/
-> .CSV file output
Pls, give me some Kudos if my response help you
Thanks for your time and attention ❤️
Hi,
I have a date format in the below form in the csv file. how can I convert this?
2015-01-01T05:00:00Z
or what is the expression used I can store in the proper format?
Please help
Hi,
Please try below.
TalendDate.parseDate("yyyy-MM-dd'T'HH:mm:ss'Z'","2015-01-01T05:00:00Z")
Regards,
thanks for the quick one...