ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <bharathi.m...@accenture.com>
Subject RE: Collection as argument to stored procedure
Date Thu, 23 Aug 2007 14:39:11 GMT

Also, is it possible to use iterate tag with insert statement?
I am trying different options, but none are giving results.
Any syntactical help in passing iterate tag to insert statement will be

-----Original Message-----
From: Mani, Bharathi 
Sent: Thursday, August 23, 2007 12:33 PM
To: 'user-java@ibatis.apache.org'; 'lmeadors@apache.org'
Subject: RE: Collection as argument to stored procedure

<parameterMap id="input" class="emp">

        <parameter property="id" jdbcType="NUMBER"
javaType="java.lang.Integer" mode="IN" />

                <parameter property="name" jdbcType="VARCHAR"
javaType="java.lang.String" mode="IN" />


    <procedure id="iterate" parameterMap="input">
      call iterate(
	    <iterate property="inputList" open="(" close=")"
                #inputList[].id, #inputList[].name
Can you please tell me the correct way to use iterate tag? Have tried
this.... (My procedure accepts a collection(inputList) of emp BOs) But
it doesn't work. Any help would be great.


-----Original Message-----
From: larry.meadors@gmail.com [mailto:larry.meadors@gmail.com] On Behalf
Of Larry Meadors
Sent: Wednesday, August 22, 2007 7:53 PM
To: user-java@ibatis.apache.org
Subject: Re: Collection as argument to stored procedure

Not really, no - Java collections are not JDBC types, so you have to
do some of the leg work.

Look at batching and the iterate tag, they'll help you get this going.


On 8/22/07, bharathi.mani@accenture.com <bharathi.mani@accenture.com>
> Hi,
> Is it possible to pass a Collection of business Objects to stored
> through iBatis? How do we do the mapping in iBatis xml file?
> Can anyone please help me in this?

This message is for the designated recipient only and may contain privileged, proprietary,
or otherwise private information.  If you have received it in error, please notify the sender
immediately and delete the original.  Any other use of the email by you is prohibited.

View raw message