You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sqoop.apache.org by "Mirek Szymanski (JIRA)" <ji...@apache.org> on 2015/09/10 14:50:45 UTC
[jira] [Created] (SQOOP-2564) Problem with Teradata input table
with INTEGER column
Mirek Szymanski created SQOOP-2564:
--------------------------------------
Summary: Problem with Teradata input table with INTEGER column
Key: SQOOP-2564
URL: https://issues.apache.org/jira/browse/SQOOP-2564
Project: Sqoop
Issue Type: Bug
Affects Versions: 1.99.6
Reporter: Mirek Szymanski
I'm trying to transfer data between Teradata and Oracle databases.
The input table in Teradata has column of type INTEGER (columntype 'I' in dbc.columnsV) to Oracle table with column INTEGER.
This results in exception:
java.lang.ClassCastException: java.lang.Integer cannot be cast to java.math.BigDecimal
at org.apache.sqoop.connector.common.SqoopIDFUtils.toCSVDecimal(SqoopIDFUtils.java:176)
at org.apache.sqoop.connector.common.SqoopIDFUtils.toCSV(SqoopIDFUtils.java:602)
at org.apache.sqoop.connector.idf.CSVIntermediateDataFormat.toCSV(CSVIntermediateDataFormat.java:116)
at org.apache.sqoop.connector.idf.CSVIntermediateDataFormat.setObjectData(CSVIntermediateDataFormat.java:87)
at org.apache.sqoop.job.mr.SqoopMapper$SqoopMapDataWriter.writeContent(SqoopMapper.java:149)
... 11 more
The fix (or maybe a workaround) is to remove the cast to BigDecimal from SqoopIDFUtils.toCSVDecimal(). When the cast is removed, my scenario works fine.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)