According to Stackoverflow
(https://stackoverflow.com/questions/13269564/java-lang-classcastexception-oracle-sql-timestamp-cannot-be-cast-to-java-sql-ti)
setting the system property accordingly should work.
Maybe you can share how you do it?
Regards,
Timo
Am 1/22/18 um 11:45 AM schrieb Puneet Kinra:
I am getting this issue while reading from the database using jdbc
connector , can you guide me how to read
from there as a string or may mapped to another type while reading
from the database
On Mon, Jan 22, 2018 at 4:12 PM, Timo Walther <twal...@apache.org
<mailto:twal...@apache.org>> wrote:
Hi Puneet,
Flink SQL does only supports java.sql.Timestamp. You need to
convert it in a user-defined function or map function accordingly.
Regards,
Timo
Am 1/22/18 um 11:38 AM schrieb Puneet Kinra:
Hi
I am getting the above error when deployed to the cluster ,trying
to set the System Property but not getting reflected inside the jobs.
I need to schedule the job as well on periodic basis , i was
thinking of calling the
jar from the CLI & put into script & schedule using cron job in
linux
but stuck with the below issue.
java.lang.ClassCastException: oracle.sql.TIMESTAMP cannot be cast
to java.sql.Timestamp
at
org.apache.flink.api.common.typeutils.base.SqlTimestampSerializer.serialize(SqlTimestampSerializer.java:27)
at
org.apache.flink.api.java.typeutils.runtime.RowSerializer.serialize(RowSerializer.java:160)
at
org.apache.flink.api.java.typeutils.runtime.RowSerializer.serialize(RowSerializer.java:46)
at
org.apache.flink.runtime.plugable.SerializationDelegate.write(SerializationDelegate.java:54)
at org.apache.flink.runtime.io
<http://org.apache.flink.runtime.io>.network.api.serialization.SpanningRecordSerializer.addRecord(SpanningRecordSerializer.java:93)
at org.apache.flink.runtime.io
<http://org.apache.flink.runtime.io>.network.api.writer.RecordWriter.sendToTarget(RecordWriter.java:114)
at org.apache.flink.runtime.io
<http://org.apache.flink.runtime.io>.network.api.writer.RecordWriter.emit(RecordWriter.java:89)
at
org.apache.flink.runtime.operators.shipping.OutputCollector.collect(OutputCollector.java:65)
at
org.apache.flink.runtime.operators.util.metrics.CountingCollector.collect(CountingCollector.java:35)
at
org.apache.flink.runtime.operators.DataSourceTask.invoke(DataSourceTask.java:168)
at
org.apache.flink.runtime.taskmanager.Task.run(Task.java:718)
at java.lang.Thread.run(Unknown Source)
--
*Cheers *
*
*
*Puneet Kinra*
*
*
*Mobile:+918800167808 | Skype : puneet.ki...@customercentria.com
<mailto:puneet.ki...@customercentria.com>*
*e-mail :puneet.ki...@customercentria.com
<mailto:puneet.ki...@customercentria.com>*
--
*Cheers *
*
*
*Puneet Kinra*
*
*
*Mobile:+918800167808 | Skype : puneet.ki...@customercentria.com
<mailto:puneet.ki...@customercentria.com>*
*e-mail :puneet.ki...@customercentria.com
<mailto:puneet.ki...@customercentria.com>*