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
awesome

-----Original Message-----
From: Mani, Bharathi 
Sent: Thursday, August 23, 2007 12:33 PM
To: '[email protected]'; '[EMAIL PROTECTED]'
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" />

  </parameterMap>

    <procedure id="iterate" parameterMap="input">
      call iterate(
            <iterate property="inputList" open="(" close=")"
               conjunction="OR">
                #inputList[].id, #inputList[].name
            </iterate>
            )
    </procedure>
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.

Thanks 
Bharathi



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf
Of Larry Meadors
Sent: Wednesday, August 22, 2007 7:53 PM
To: [email protected]
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.

Larry


On 8/22/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]>
wrote:
>
> Hi,
>
> Is it possible to pass a Collection of business Objects to stored
procedure
> 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.

Reply via email to