Talend Connect
Virtual Summit
JOIN US!
And visit the Customer
& Community Lounge.
May 27-28, wherever you are.

DateTime sepration tmap to Mysql Workbench

Highlighted
Four Stars

DateTime sepration tmap to Mysql Workbench

Hello,

 

I have been trying to delete time from DateTime String to Date format "yyyy-MM-dd" using tmap component.

My components are:     tFileInputDelimited to tmap to tLogRow to tMysqlOutput

When I excute the job there are no errors and in the tLogRow everything looks perfectly fine as I needed. However, I get the date format as "yyyy-MM-dd hh:mm:ss" instead of "yyyy-MM-dd" in the final output which is tMysqlOutput (in my case am using Mysql Workbench).

 

I have used the expression : TalendDate.parseDate("yyyy-MM-dd",row1.Date) 

IMAGES ATTACHED

tmap.pngtlogrow.pngMysql Workbench.png

 

 

Thank you for helping guys,

Sherif

Highlighted
Eleven Stars

Re: DateTime sepration tmap to Mysql Workbench

what is datatype of column in database ? is it date , datetime or timestamp? if it is not date type , it will display timestamp.

 

Regards
Abhishek KUMAR
Highlighted
Employee

Re: DateTime sepration tmap to Mysql Workbench

Hi,

 

    This looks like the data's timezone is getting changed by 1 hour while loading to MySQL server.

 

     Could you please try to load the date column where your timezone is explicitly mentioned in the output of tMap?

 

     It may resolve the issue.

 

Warm Regards,
Nikhil Thampi

Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved :-)

2019 GARTNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

Best Practices for Using Context Variables with Talend – Part 2

Part 2 of a series on Context Variables

Blog

Best Practices for Using Context Variables with Talend – Part 1

Learn how to do cool things with Context Variables

Blog

Migrate Data from one Database to another with one Job using the Dynamic Schema

Find out how to migrate from one database to another using the Dynamic schema

Blog