java - JPA query compare lists -
let's have entity this:
public class class1 { private long id; ... private list<onerandomobject> list; }
is possible in jpa criteria query or named query compare entities lists?
something named query:
select c class1 c c.list=:list
queries using criteria api work fine well.
as far know, it's impossible filter whole collection property.
maybe can try class1 along the list
conditions, , filter result below:
for(class1 c1 : class1list) { list<onerandomobject> list = c1.getlist(); // compare list param // remove if not match }
Comments
Post a Comment