You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user-java@ibatis.apache.org by Philippe Laflamme <ph...@mail.mcgill.ca> on 2004/12/06 16:18:28 UTC

Iterate property references

Hi,

I'm wondering if somthing like this was possible:

<iterate property="names" open="(" close=")" conjunction="OR">
	<isEqual property="names[]" compareValue="aName">
		colValue = 1
	</isEqual>
	<isEqual property="names[]" compareValue="anotherName">
		colValue = 2
	</isEqual>
</iterate>

As you may have noticed the braketed porperty is referenced in an isEqual
tag, not directly as the value in a WHERE clause...

I haven't tried it but I came up with a situation that could have required
this. I was wondering if it was handled by iBatis' tags.

Thanks,
Philippe


Re: Iterate property references

Posted by Clinton Begin <cl...@gmail.com>.
At this time it is not.  We're investigating scripting alternatives,
and possibly simply extending the current implementation to support
such things.

Cheers,
Clinton


On Mon, 6 Dec 2004 10:18:28 -0500, Philippe Laflamme
<ph...@mail.mcgill.ca> wrote:
> Hi,
> 
> I'm wondering if somthing like this was possible:
> 
> <iterate property="names" open="(" close=")" conjunction="OR">
>         <isEqual property="names[]" compareValue="aName">
>                 colValue = 1
>         </isEqual>
>         <isEqual property="names[]" compareValue="anotherName">
>                 colValue = 2
>         </isEqual>
> </iterate>
> 
> As you may have noticed the braketed porperty is referenced in an isEqual
> tag, not directly as the value in a WHERE clause...
> 
> I haven't tried it but I came up with a situation that could have required
> this. I was wondering if it was handled by iBatis' tags.
> 
> Thanks,
> Philippe
> 
>