Community Articles
Find and share helpful community-sourced technical articles
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.
Labels (1)
New Contributor

PROBLEM:

In hive, on oracle metastore following error is observed for table creation,

java.sql.SQLException: ORA-01461: can bind a LONG value only for insert into a LONG column

ROOT CAUSE:

Issue looks to be due to large number of columns in this table.

RESOLUTION:

Currently hive will we store column stats in a table while we store the accuracy in another table (table properites). The best way is to store both the column stats and its accuracy in the same table. This involves modification of schema.

This has been addressed in https://hortonworks.jira.com/browse/BUG-84234

As a workaround we can change the column type to CLOB.

314 Views
Comments
New Contributor

Oracle LONG columns are a nasty biz. They work with practically no other SQL or PL/SQL data types. Depending on the actual version of the DBMS, VARCHAR2 values can get treated as LONG and cause errors like this.

Don't have an account?
Coming from Hortonworks? Activate your account here
Version history
Revision #:
1 of 1
Last update:
‎09-29-2017 08:13 AM
Updated by:
 
Contributors
Top Kudoed Authors