[jboss-user] [JBoss Seam] - How to use in (#{exampleList}) in HibernateEntityQuery

so38 do-not-reply at jboss.com
Wed Feb 6 17:43:30 EST 2008


Is it possible to use the in statement in an EntityQuery restriction.  I am trying to do something like the following:


  | <framework:hibernate-entity-query name="testList"
  |     ejbql="select test from Test test" >
  |     <framework:restrictions>
  |       <value>test.name in #{exampleNameList}</value>
  |     </framework:restrictions>
  |   </framework:hibernate-entity-query>
  | 

However when I try to do this I get an error with the following cause:

  | Caused by java.lang.ClassCastException with message: "java.util.ArrayList"
  | 

The same happens when I extend HibernateEntityQuery.  Has any one else been able to figure out how to do this? Or, does anyone know if it is even possible?

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4127202#4127202

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4127202



More information about the jboss-user mailing list