[ https://issues.apache.org/jira/browse/FLINK-12204?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16818512#comment-16818512 ]
Hequn Cheng edited comment on FLINK-12204 at 4/16/19 2:24 AM: -------------------------------------------------------------- [~fan_li_ya] Glad that you are also interested in this. I have already finished this in my local branch. The exception would be {code:java} Caused by: java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer at index 1 of output row. at org.apache.flink.api.java.io.jdbc.JDBCOutputFormat.writeRecord(JDBCOutputFormat.java:153) at org.apache.flink.api.java.io.jdbc.JDBCOutputFormat.writeRecord(JDBCOutputFormat.java:41) at org.apache.flink.runtime.operators.DataSinkTask.invoke(DataSinkTask.java:218) at org.apache.flink.runtime.taskmanager.Task.run(Task.java:718) at java.lang.Thread.run(Thread.java:748) {code} If you don't mind I will open a PR soon. However, if you are still interested it and want to give it a try. I can free this issue to you. :) was (Author: hequn8128): [~fan_li_ya] Glad that you are also interested in this. I have already finished this in my local branch. The exception would be {code:java} Caused by: java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer for index 1. at org.apache.flink.api.java.io.jdbc.JDBCOutputFormat.writeRecord(JDBCOutputFormat.java:153) at org.apache.flink.api.java.io.jdbc.JDBCOutputFormat.writeRecord(JDBCOutputFormat.java:41) at org.apache.flink.runtime.operators.DataSinkTask.invoke(DataSinkTask.java:218) at org.apache.flink.runtime.taskmanager.Task.run(Task.java:718) at java.lang.Thread.run(Thread.java:748) {code} If you don't mind I will open a PR soon. However, if you are still interested it and want to give it a try. I can free this issue to you. :) > Improve JDBCOutputFormat ClassCastException > ------------------------------------------- > > Key: FLINK-12204 > URL: https://issues.apache.org/jira/browse/FLINK-12204 > Project: Flink > Issue Type: Task > Components: Connectors / JDBC > Affects Versions: 1.8.0 > Reporter: Fabian Hueske > Assignee: Hequn Cheng > Priority: Major > Fix For: 1.9.0, 1.8.1 > > > ClassCastExceptions thrown by JDBCOutputFormat are not very helpful because > they do not provide information for which input field the cast failed. > We should catch the exception and enrich it with information about the > affected field to make it more useful. -- This message was sent by Atlassian JIRA (v7.6.3#76005)