[resolved] Issue in date format while inserting record in table of MYSQL database

Four Stars

[resolved] Issue in date format while inserting record in table of MYSQL database

Hi All,
I want to capture job success status value in table "talend_job_status" once the job execution is successful.
My schema for tMySQLRow component is given below :-

My Query in this component is as follows :- 
"INSERT INTO talend_job_status 
VALUES ('"+jobName+"','"+TalendDate.getDate("MM/dd/yyyy HH:mm:ss")+"',1)"

Schema of table "talend_job_status" is given below:-

But once job execution is complete I am unable to capture status because I am getting error which is as follows :- 

Can anyone please suggest me what is wrong in my talend development ? Valuable suggestion is welcome.

Accepted Solutions
Thirteen Stars

Re: [resolved] Issue in date format while inserting record in table of MYSQL database

https://dev.mysql.com/doc/refman/5.7/en/datetime.html
presentation forms could be many, so - just test it
-----------

All Replies
Thirteen Stars

Re: [resolved] Issue in date format while inserting record in table of MYSQL database

default forMySQL datetime format = yyyy-MM-dd HH:mm:ss
if You have 03/07/2017 15:54:39 in source, You need convert it to proper format
-----------
Four Stars

Re: [resolved] Issue in date format while inserting record in table of MYSQL database

Hi,
Thanks for your reply.
But we I execute SELECT query the data is shown below :- 
Format of date is different here 
Thirteen Stars

Re: [resolved] Issue in date format while inserting record in table of MYSQL database

https://dev.mysql.com/doc/refman/5.7/en/datetime.html
presentation forms could be many, so - just test it
-----------