ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Abi Bala" <abja...@gmail.com>
Subject can bind a LONG value only for insert into a LONG column
Date Fri, 12 Oct 2007 18:48:05 GMT
Hi all,

We are using iBatis in our project and Oracle 9i JDBC Driver.
When trying to insert/update columns with Data type VARCHAR2(4000) using
inline parameters works fine when the data to be inserted is smaller.
But when the data to be inserted is near 4000 characters,the following
exception occurrs.

--- Cause: java.sql.SQLException: ORA-01461: can bind a LONG value only for
insert into a LONG column
; PREVIOUS EXCEPTION: (com.ibatis.common.jdbc.exception.NestedSQLException:

The data to be inserted is a String object.Why does it throw a "LONG" value
exception?

Also tried with parameter maps having declared as below:

<parameter property="commentText" javaType="java.lang.String"
jdbcType="LONGVARCHAR" typeHandler="
com.ibatis.sqlmap.engine.type.StringTypeHandler" nullValue="VARCHAR"/>

But still getting the same exception.

Thanks in advance.

Mime
View raw message