Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
ichart
Contributor
Contributor

[resolved] xml file to map :tXMLMap_1_TXMLMAP_OUT Unparseable date

Hello all!
I stripped my process to the bare minimum. tFileInoutXML - > tXMLMap ->tLogrow
 with 2 field : TransmissionCode (string) and TransmissionDateTime (dateTime).
The date in the file is : 2017-03-17T20:17:03
The output of the tFileInoutXML is a Type Document.
In the tXMLMAp I defined the field TransmissionDateTime as a Date with Date pattern: "yyyy-MM-dd'T'HH:mm:ss"
Yet it crash with tXMLMap_1_TXMLMAP_OUT Unparseable date: "2017-03-17T20:17:03"
Exception in component tXMLMap_1_TXMLMAP_OUT
java.lang.RuntimeException: Unparseable date: "2017-03-17T20:17:03"
If I check the code I see the folowing:
Header_tmp.TransmissionDateTime = treeNodeAPI_tXMLMap_1_TXMLMAP_OUT
                                            .get_Date(
                                                    "ColtraneFile.Coltrane:/CollegeTransmission/Header/TransmissionDateTime",
                                                     "dd-MM-yyyy");
Now where and why do the treeNodeAPI_tXMLMap_1_TXMLMAP_OUT is calling getDate( "dd-MM-yyyy") ?
Thank you for your help,
Isabelle
Labels (4)
1 Solution

Accepted Solutions
Anonymous
Not applicable

Hi  
In the input schema, define the date pattern as "yyyy-MM-dd'T'HH:mm:ss" also, it should work now.

0683p000009LwZ7.png

Regards
Shong

View solution in original post

6 Replies
Anonymous
Not applicable

Hi 
I am trying to reproduce the issue, can you please upload some screenshots of your job or export your job and send it to me via email?
Regards
Shong
ichart
Contributor
Contributor
Author

Hi Shong,
I send you an email titled
export of job for
Thank yo uso much for your help,
Isabelle
Anonymous
Not applicable

Hi  
In the input schema, define the date pattern as "yyyy-MM-dd'T'HH:mm:ss" also, it should work now.

0683p000009LwZ7.png

Regards
Shong

ichart
Contributor
Contributor
Author

That flew right past me,
Thank you so very much, this is a good way to start a week!
Anonymous
Not applicable

Request for Quick help

Facing an similar issue as below.

 

Starting job Test_Job_1 at 14:37 11/03/2020.

[statistics] connecting to socket on port 3746
[statistics] connected
Exception in component tXMLMap_3_TXMLMAP_OUT (Test_Job_1)
java.lang.RuntimeException: Unparseable date: "2020-02-14T09:52:42Z"
at routines.system.ParserUtils.parseTo_Date(ParserUtils.java:339)
at bat_integration.test_job_1_0_1.Test_Job_1$1TreeNode_API_tXMLMap_3_TXMLMAP_OUT.get_Date(Test_Job_1.java:2505)
at bat_integration.test_job_1_0_1.Test_Job_1.tRESTClient_2Process(Test_Job_1.java:3311)
at bat_integration.test_job_1_0_1.Test_Job_1.tFileInputDelimited_1Process(Test_Job_1.java:1514)
at bat_integration.test_job_1_0_1.Test_Job_1.runJobInTOS(Test_Job_1.java:4330)
at bat_integration.test_job_1_0_1.Test_Job_1.main(Test_Job_1.java:4084)
[FATAL]: bat_integration.test_job_1_0_1.Test_Job_1 - tXMLMap_3_TXMLMAP_OUT Unparseable date: "2020-02-14T09:52:42Z"
java.lang.RuntimeException: Unparseable date: "2020-02-14T09:52:42Z"
at routines.system.ParserUtils.parseTo_Date(ParserUtils.java:339)
at bat_integration.test_job_1_0_1.Test_Job_1$1TreeNode_API_tXMLMap_3_TXMLMAP_OUT.get_Date(Test_Job_1.java:2505)
at bat_integration.test_job_1_0_1.Test_Job_1.tRESTClient_2Process(Test_Job_1.java:3311)
at bat_integration.test_job_1_0_1.Test_Job_1.tFileInputDelimited_1Process(Test_Job_1.java:1514)
at bat_integration.test_job_1_0_1.Test_Job_1.runJobInTOS(Test_Job_1.java:4330)
at bat_integration.test_job_1_0_1.Test_Job_1.main(Test_Job_1.java:4084)
[statistics] disconnected

Job Test_Job_1 ended at 14:37 11/03/2020. [exit code=1]


code.PNG
Brian_G
Contributor
Contributor

Note to people who are using a more recent version of Talend. It is not called "input schema". The 2nd tab on the input of the tXMLMap component is labeled "TreeSchemaEditor". You can change the pattern of the date there. After a couple hours of frustration, I came across this post and got my issue to work!