Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
JPA: Using collection.any().in(...) in element collections #217
When using collection.any().in(...) in a collection path representing a collection of elements (not persistent entities), the generated JPQL contains "from ElementClass alias ...", which is invalid.
QUser u = QUser.user1; from(u).where(u.roles.any().in(Role.ADMIN, Role.MANAGER);
select u from User u where exists ( select 1 from User u1 join u1.roles r where u1 = u and r in :roles )