ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "a.rubalcaba" <a.rubalc...@yahoo.com>
Subject Re: Ibatis CLOB Support
Date Sun, 29 Mar 2009 15:28:02 GMT

a.rubalcaba wrote:
> I am currently working on a project using Spring + Ibatis.  DBA's have
> recently switched a varchar field into a CLOB field to support large
> Strings of data.  
> My SQL map has the following
>   <result property="filters" column="FILTER_DATA" jdbcType="CLOB"/>
> which maps to a String object in my java class.
> I can retrieve data ok. Its when I try to insert data that I get the
> following error.  
> java.sql.SQLException: ORA-01704: string literal too long
> I am using the classes12.jar JDBC driver, Ibatis  2.2.0, and Spring 2.0
> Any help on this issue would be greatly appreciated. 

I got rid of the ORA-01704: string literal too long error. My new issue is I
keep getting the following error.

--- Check the parameter mapping for the 'id' property.
--- Cause: java.sql.SQLException: Invalid column index

Here is my parameter Map:
<parameterMap class="chartFavoriteVO" id="chartParameter" >
<parameter property="id" javaType="int" jdbcType="NUMBER" />
<parameter property="chartName" javaType="string" jdbcType="VARCHAR2"/>
<parameter property="userId" javaType="string" jdbcType="VARCHAR2"/>
<parameter property="filters" jdbcType="CLOB" javaType="string"
<parameter property="publicInd" javaType="string" jdbcType="CHAR"/>
<parameter property="groupBy" javaType="string" jdbcType="VARCHAR2"/>
<parameter property="chartType" javaType="int" jdbcType="NUMBER"/>
<parameter property="chartNotes" javaType="string" jdbcType="VARCHAR2"/>
<parameter property="measureData" javaType="string" jdbcType="VARCHAR2"/>
<parameter property="orderBy" javaType="string" jdbcType="VARCHAR2"/>
<parameter property="sortOrder" javaType="string" jdbcType="VARCHAR2"/>


Here is my insert

<insert id="insertChartFavorite" parameterMap="chartParameter">
values ($id$,'$chartName$','$userId$','$filters$','$group

I'm trying to figureout what I'm missing and why I keep getting this error.
I tried removing some of the fields and inserting only the 3 needed fields
and that didn't work either.

View this message in context: http://www.nabble.com/Ibatis-CLOB-Support-tp22745185p22768773.html
Sent from the iBATIS - User - Java mailing list archive at Nabble.com.

View raw message