Java Mailing List Archive

http://www.gg3721.com/

Home » users.openjpa »

Re: [JPQL] Problem statement SELECT ... IN () , with parameters

CG

2008-08-13

Replies: Find Java Web Hosting

Author LoginPost Reply
Thanks! It works!

CG

On Tue, Aug 12, 2008 at 1:53 AM, Pinaki Poddar <ppoddar@(protected):
>
> Hi,
>> q.setParameter("roleIds", sb.toString());
>
> Set the IN parameter not as a String but a List<T> where T is the type of
> Role.id.
>
> For example, if Role.id is int, then
>  q.setParameter("roleIds", Arrays.asList(new int[]{1,2}));
>
>
> --
> View this message in context: http://n2.nabble.com/-JPQL--Problem-statement-SELECT-...-IN-%28%29-%2C-with-parameters-tp686295p686459.html
> Sent from the OpenJPA Users mailing list archive at Nabble.com.
>
>
©2008 gg3721.com - Jax Systems, LLC, U.S.A.