Casting date in Talend Data Integration -
in data flow 1 table another, cast date.
the date leaves source table string in format: "2009-01-05 00:00:00:000 + 01:00".
i tried convert date using tconverttype, not allowed apparently. second option cast string date using formula in tmap component.
at moment tried these formulas:
- talenddate.formatdate("yyyy-mm-dd",row3.rafw_dz_begi); - talenddate.formatdate("yyyy-mm-dd hh:mm:ss",row3.rafw_dz_begi); - return talenddate.formatdate("yyyy-mm-dd hh:mm:ss",row3.rafw_dz_begi);
none of these worked. when inserting result target-table (mysql, innodb) receive error message date not valid. format of target field mysql date field.
how can cast date desired format?
talend offers nice way of handling date formats. can change date format in schema editor tab @ tmap
window.
it works both tmap
input , output flows. i've added picture better illustration.
Comments
Post a Comment